Exceptions attribute (JVMS 4.7.5), which records the exceptions declared to be thrown by this
method.
This attribute only appears on methods, and does not permit multiple instances in a method. It has a data dependency on the constant pool.
The attribute was introduced in the Java Platform version 1.0.2, major version 45.
API Note
Generic exceptions types thrown by a method and potentially annotated use of
those types are defined by SignatureAttribute and RuntimeVisibleTypeAnnotationsAttribute respectively, which requires this
attribute to be present.
Exceptions Attribute
Attributes#exceptions()
| Modifier and Type | Method and Description |
|---|---|
| public List | Returns: the exceptions declared to be thrown by this methodReturns the exceptions declared to be thrown by this method. |
| public static ExceptionsAttribute | Returns: anExceptions attributethe exceptions that may be thrown from this method exceptions)Returns an |
| public static ExceptionsAttribute | Returns: anExceptions attributethe exceptions that may be thrown from this method exceptions)Returns an |
| public static ExceptionsAttribute | |
| public static ExceptionsAttribute |
| exceptions | back to summary |
|---|---|
| public List Returns the exceptions declared to be thrown by this method.
| |
| of | back to summary |
|---|---|
| public static ExceptionsAttribute of(List<ClassEntry> exceptions) Returns an
| |
| of | back to summary |
|---|---|
| public static ExceptionsAttribute of(ClassEntry... exceptions) Returns an
| |
| ofSymbols | back to summary |
|---|---|
| public static ExceptionsAttribute ofSymbols(List<ClassDesc> exceptions) Returns an
| |
| ofSymbols | back to summary |
|---|---|
| public static ExceptionsAttribute ofSymbols(ClassDesc... exceptions) Returns an
| |