new AssertionError(<i>expression</i>)
has as its detail message the string conversion of expression (as defined in section {
Added in 1.4.
Java documentation for java.lang.AssertionError
.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.
Constructs an AssertionError with its detail message derived
from the specified boolean
, which is converted to
a string as defined in section {
Constructs an AssertionError with its detail message derived
from the specified char
, which is converted to a
string as defined in section {
Constructs an AssertionError with its detail message derived
from the specified double
, which is converted to a
string as defined in section {
Constructs an AssertionError with its detail message derived
from the specified int
, which is converted to a
string as defined in section {
Constructs an AssertionError with its detail message derived
from the specified long
, which is converted to a
string as defined in section {
Constructs an AssertionError with its detail message derived
from the specified object, which is converted to a string as
defined in section {
Constructs an AssertionError with its detail message derived
from the specified float
, which is converted to a
string as defined in section {
Appends the specified exception to the exceptions that were
suppressed in order to deliver this exception.
(Inherited from Throwable)
Provides programmatic access to the stack trace information printed by
#printStackTrace()
.
(Inherited from Throwable)
Returns an array containing all of the exceptions that were
suppressed, typically by the try
-with-resources
statement, in order to deliver this exception.
(Inherited from Throwable)
Sets the stack trace elements that will be returned by
#getStackTrace()
and printed by #printStackTrace()
and related methods.
(Inherited from Throwable)