Name
Error
Synopsis
Error
is a subclass of Throwable
.
It is the base class for exceptions that are not likely to be recoverable
by application code, but also do not represent programming errors (and hence
are not derived from RuntimeException
). Methods that might
throw Error
s are not required to indicate that
fact by including a throws
declaration. In the same
manner, code that calls such a method is not required to catch the
Error
.
The number of Error
subclasses defined by CLDC is much
less than the number that exist in J2SE, primarily because the cause of
most errors on this platform is device-specific and therefore not
susceptible to common handling by platform-independent code. Errors that are
reported as such in J2SE are often regarded as terminal conditions
that should halt the execution of the virtual machine in CLDC.
This class is the same as its J2SE equivalent, apart from its inability to be serialized.
public class Error extends Throwable { // Public Constructors public Error(); public Error( String s); }
Subclasses
VirtualMachineError
Get J2ME in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.