public class ExceptionsAttribute extends AttributeInfo
Exceptions_attribute.| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
tag
The name of this attribute
"Exceptions". |
constPool, info, name| Modifier | Constructor and Description |
|---|---|
|
ExceptionsAttribute(ConstPool cp)
Constructs a new exceptions attribute.
|
private |
ExceptionsAttribute(ConstPool cp,
ExceptionsAttribute src,
java.util.Map classnames)
Constructs a copy of an exceptions attribute.
|
(package private) |
ExceptionsAttribute(ConstPool cp,
int n,
java.io.DataInputStream in) |
| Modifier and Type | Method and Description |
|---|---|
AttributeInfo |
copy(ConstPool newCp,
java.util.Map classnames)
Makes a copy.
|
private void |
copyFrom(ExceptionsAttribute srcAttr,
java.util.Map classnames)
Copies the contents from a source attribute.
|
int |
getException(int nth)
Returns the value of
exception_index_table[nth]. |
int[] |
getExceptionIndexes()
Returns
exception_index_table[]. |
java.lang.String[] |
getExceptions()
Returns the names of exceptions that the method may throw.
|
void |
setExceptionIndexes(int[] elist)
Sets
exception_index_table[]. |
void |
setExceptions(java.lang.String[] elist)
Sets the names of exceptions that the method may throw.
|
int |
tableLength()
Returns
number_of_exceptions. |
copyAll, get, getConstPool, getLength, getName, getRefClasses, getRefClasses, length, lookup, read, remove, renameClass, renameClass, renameClass, renameClass, set, write, writeAllpublic static final java.lang.String tag
"Exceptions".ExceptionsAttribute(ConstPool cp, int n, java.io.DataInputStream in) throws java.io.IOException
java.io.IOExceptionprivate ExceptionsAttribute(ConstPool cp, ExceptionsAttribute src, java.util.Map classnames)
cp - constant pool table.src - source attribute.public ExceptionsAttribute(ConstPool cp)
cp - constant pool table.public AttributeInfo copy(ConstPool newCp, java.util.Map classnames)
Map object.copy in class AttributeInfonewCp - the constant pool table used by the new copy.classnames - pairs of replaced and substituted
class names. It can be null.private void copyFrom(ExceptionsAttribute srcAttr, java.util.Map classnames)
srcAttr - source Exceptions attributeclassnames - pairs of replaced and substituted
class names.public int[] getExceptionIndexes()
exception_index_table[].public java.lang.String[] getExceptions()
public void setExceptionIndexes(int[] elist)
exception_index_table[].public void setExceptions(java.lang.String[] elist)
public int tableLength()
number_of_exceptions.public int getException(int nth)
exception_index_table[nth].