Overview | Package | Class | Use | Tree | Deprecated | Index
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## javassist.bytecode
Class ExceptionsAttribute

    java.lang.Object
      |
      +--javassist.bytecode.AttributeInfo
            |
            +--javassist.bytecode.ExceptionsAttribute

public class ExceptionsAttribute
extends AttributeInfo

`Exceptions_attribute`.

Field Summary
`static java.lang.String` | `tag` The name of this attribute `"Exceptions"`.

Constructor Summary
`ExceptionsAttribute(ConstPool cp)` Constructs a new exceptions attribute.

Method Summary
`AttributeInfo` | `copy(ConstPool newCp, java.util.Map classnames)` Makes a copy.
`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.
`int` | `length()` Returns `number_of_exceptions`.
`void` | `setExceptionIndexes(int[] elist)` Sets `exception_index_table[]`.
`void` | `setExceptions(java.lang.String[] elist)` Sets the names of exceptions that the method may throw.

Methods inherited from class javassist.bytecode.AttributeInfo
`get, getConstPool, getName, set`

Methods inherited from class java.lang.Object
`equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### tag

    public static final java.lang.String tag

  The name of this attribute `"Exceptions"`.

  See Also:
    Constant Field Values

Constructor Detail

### ExceptionsAttribute

    public ExceptionsAttribute(ConstPool cp)

  Constructs a new exceptions attribute.

Parameters:
  `cp` - constant pool table.

Method Detail

### copy

    public AttributeInfo copy(ConstPool newCp,
                              java.util.Map classnames)

  Makes a copy. Class names are replaced according to the given `Map` object.

  Overrides:
    `copy` in class `AttributeInfo`
  Parameters:
    `newCp` - the constant pool table used by the new copy.
    `classnames` - pairs of replaced and substituted class names.

### getExceptionIndexes

    public int[] getExceptionIndexes()

  Returns `exception_index_table[]`.

### getExceptions

    public java.lang.String[] getExceptions()

  Returns the names of exceptions that the method may throw.

### setExceptionIndexes

    public void setExceptionIndexes(int[] elist)

  Sets `exception_index_table[]`.

### setExceptions

    public void setExceptions(java.lang.String[] elist)

  Sets the names of exceptions that the method may throw.

### length

    public int length()

  Returns `number_of_exceptions`.

  Overrides:
    `length` in class `AttributeInfo`

### getException

    public int getException(int nth)

  Returns the value of `exception_index_table[nth]`.

Overview | Package | Class | Use | Tree | Deprecated | Index
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Javassist, a Java-bytecode translator toolkit. Copyright (C) 1999-2003 Shigeru Chiba. All Rights Reserved.