| Modifier and Type | Class and Description |
|---|---|
| private static class | SymbolTable.Entry
An entry of a SymbolTable. |
| Modifier and Type | Field and Description |
|---|---|
| private int | bootstrapMethodCount
The number of bootstrap methods in |
| private ByteVector | bootstrapMethods
The content of the BootstrapMethods attribute 'bootstrap_methods' array corresponding to this SymbolTable. |
| private String | className
The internal name of the class to which this symbol table belongs. |
| pack-priv final ClassWriter | classWriter
The ClassWriter to which this SymbolTable belongs. |
| private ByteVector | constantPool
The content of the ClassFile's constant_pool JVMS structure corresponding to this SymbolTable. |
| private int | constantPoolCount
The number of constant pool items in |
| private SymbolTable. | entries
A hash set of all the entries in this SymbolTable (this includes the constant pool entries, the bootstrap method entries and the type table entries). |
| private int | |
| private int | majorVersion
The major version number of the class to which this symbol table belongs. |
| private final ClassReader | sourceClassReader
The ClassReader from which this SymbolTable was constructed, or null if it was constructed from scratch. |
| private int | |
| private SymbolTable. | typeTable
An ASM specific type table used to temporarily store internal names that will not necessarily be stored in the constant pool. |
| Access | Constructor and Description |
|---|---|
| pack-priv | SymbolTable(final ClassWriter
a ClassWriter. classWriter)Constructs a new, empty SymbolTable for the given ClassWriter. |
| pack-priv | SymbolTable(final ClassWriter
a ClassWriter. classWriter, final ClassReader the ClassReader whose constant pool and bootstrap methods must be copied to
initialize the SymbolTable. classReader)Constructs a new SymbolTable for the given ClassWriter, initialized with the constant pool and bootstrap methods of the given ClassReader. |
| Modifier and Type | Method and Description |
|---|---|
| private void | add(final SymbolTable.
an Entry (which must not already be contained in entryentries).Adds the given entry in the |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a bootstrap method handle. bootstrapMethodHandle, final Object... the bootstrap method arguments. bootstrapMethodArguments)Adds a bootstrap method to the BootstrapMethods attribute of this symbol table. |
| private Symbol | Returns: a new or already existing Symbol with the given value.the offset of the last bootstrap method in offset, final int bootstrapMethods, in bytes.the length of this bootstrap method in length, final int bootstrapMethods, in bytes.the hash code of this bootstrap method. hashCode)Adds a bootstrap method to the BootstrapMethods attribute of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.Adds a number or string constant to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.the internal name of a class. value)Adds a CONSTANT_Class_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a double. value)Adds a CONSTANT_Double_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a method name. name, final String a field descriptor. descriptor, final Handle a bootstrap method handle. bootstrapMethodHandle, final Object... the bootstrap method arguments. bootstrapMethodArguments)Adds a CONSTANT_Dynamic_info to the constant pool of this symbol table. |
| private Symbol | Returns: a new or already existing Symbol with the given value.a method name. name, final String a field descriptor for CONSTANT_DYNAMIC_TAG) or a method descriptor for
CONSTANT_INVOKE_DYNAMIC_TAG. descriptor, final int the index of a bootstrap method in the BootstrapMethods attribute. bootstrapMethodIndex)Adds a CONSTANT_Dynamic or a CONSTANT_InvokeDynamic_info to the constant pool of this symbol table. |
| private void | addConstantDynamicOrInvokeDynamicReference(final int tag, final int
the constant pool index of the new Symbol. index, final String a method name. name, final String a field descriptor for CONSTANT_DYNAMIC_TAG or a method descriptor for
CONSTANT_INVOKE_DYNAMIC_TAG. descriptor, final int the index of a bootstrap method in the BootstrapMethods attribute. bootstrapMethodIndex)Adds a new CONSTANT_Dynamic_info or CONSTANT_InvokeDynamic_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.the internal name of a class. owner, final String a field name. name, final String a field descriptor. descriptor)Adds a CONSTANT_Fieldref_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a float. value)Adds a CONSTANT_Float_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.an int. value)Adds a CONSTANT_Integer_info to the constant pool of this symbol table. |
| private Symbol | Returns: a constant pool constant with the given tag and primitive values.an int or float. value)Adds a CONSTANT_Integer_info or CONSTANT_Float_info to the constant pool of this symbol table. |
| private void | addConstantIntegerOrFloat(final int
the constant pool index of the new Symbol. index, final int tag, final int an int or float. value)Adds a new CONSTANT_Integer_info or CONSTANT_Float_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a method name. name, final String a method descriptor. descriptor, final Handle a bootstrap method handle. bootstrapMethodHandle, final Object... the bootstrap method arguments. bootstrapMethodArguments)Adds a CONSTANT_InvokeDynamic_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a long. value)Adds a CONSTANT_Long_info to the constant pool of this symbol table. |
| private Symbol | Returns: a constant pool constant with the given tag and primitive values.a long or double. value)Adds a CONSTANT_Long_info or CONSTANT_Double_info to the constant pool of this symbol table. |
| private void | addConstantLongOrDouble(final int
the constant pool index of the new Symbol. index, final int tag, final long a long or double. value)Adds a new CONSTANT_Long_info or CONSTANT_Double_info to the constant pool of this symbol table. |
| private SymbolTable. | Returns: a new or already existing Symbol with the given value.the internal name of a class. owner, final String a field or method name. name, final String a field or method descriptor. descriptor)Adds a CONSTANT_Fieldref_info, CONSTANT_Methodref_info or CONSTANT_InterfaceMethodref_info to the constant pool of this symbol table. |
| private void | addConstantMemberReference(final int
the constant pool index of the new Symbol. index, final int tag, final String the internal name of a class. owner, final String a field or method name. name, final String a field or method descriptor. descriptor)Adds a new CONSTANT_Fieldref_info, CONSTANT_Methodref_info or CONSTANT_InterfaceMethodref_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.the internal name of a class of interface. owner, final String a field or method name. name, final String a field or method descriptor. descriptor, final boolean whether owner is an interface or not. isInterface)Adds a CONSTANT_MethodHandle_info to the constant pool of this symbol table. |
| private void | addConstantMethodHandle(final int
the constant pool index of the new Symbol. index, final int referenceKind, final String the internal name of a class of interface. owner, final String a field or method name. name, final String a field or method descriptor. descriptor)Adds a new CONSTANT_MethodHandle_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.the internal name of a class. owner, final String a method name. name, final String a method descriptor. descriptor, final boolean whether owner is an interface or not. isInterface)Adds a CONSTANT_Methodref_info or CONSTANT_InterfaceMethodref_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a method descriptor. methodDescriptor)Adds a CONSTANT_MethodType_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a fully qualified name (using dots) of a module. moduleName)Adds a CONSTANT_Module_info to the constant pool of this symbol table. |
| pack-priv int | Returns: a new or already existing Symbol with the given value.a field or method name. name, final String a field or method descriptor. descriptor)Adds a CONSTANT_NameAndType_info to the constant pool of this symbol table. |
| private void | addConstantNameAndType(final int
the constant pool index of the new Symbol. index, final String a field or method name. name, final String a field or method descriptor. descriptor)Adds a new CONSTANT_NameAndType_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.the internal name of a package. packageName)Adds a CONSTANT_Package_info to the constant pool of this symbol table. |
| pack-priv Symbol | Returns: a new or already existing Symbol with the given value.a string. value)Adds a CONSTANT_String_info to the constant pool of this symbol table. |
| pack-priv int | Returns: a new or already existing Symbol with the given value.a string. value)Adds a CONSTANT_Utf8_info to the constant pool of this symbol table. |
| private void | addConstantUtf8(final int
the constant pool index of the new Symbol. index, final String a string. value)Adds a new CONSTANT_String_info to the constant pool of this symbol table. |
| private Symbol | Returns: a new or already existing Symbol with the given value.an internal class name, an arbitrary string, a method descriptor, a module or a
package name, depending on tag. value)Adds a CONSTANT_Class_info, CONSTANT_String_info, CONSTANT_MethodType_info, CONSTANT_Module_info or CONSTANT_Package_info to the constant pool of this symbol table. |
| private void | addConstantUtf8Reference(final int
the constant pool index of the new Symbol. index, final int tag, final String an internal class name, an arbitrary string, a method descriptor, a module or a
package name, depending on tag. value)Adds a new CONSTANT_Class_info, CONSTANT_String_info, CONSTANT_MethodType_info, CONSTANT_Module_info or CONSTANT_Package_info to the constant pool of this symbol table. |
| pack-priv int | Returns: the index of a new or already existingSymbol#TYPE_TAG type Symbol,
corresponding to the common super class of the given types.a typeTableIndex1, final int Symbol#TYPE_TAG type, specified by its index in the type
table.another typeTableIndex2)Symbol#TYPE_TAG type, specified by its index in the type
table.Adds a merged type in the type table of this symbol table. |
| pack-priv int | |
| private int | Returns: the index intypeTable where the given type was added, which is also equal to
entry's index by hypothesis.a entrySymbol#TYPE_TAG or Symbol#UNINITIALIZED_TYPE_TAG type symbol.
The index of this Symbol must be equal to the current value of typeCount.Adds the given type Symbol to |
| pack-priv int | Returns: the index of a new or already existing type Symbol with the given value.an internal class name. value, final int the bytecode offset of the NEW instruction that created this bytecodeOffset)Frame#ITEM_UNINITIALIZED type value.Adds an |
| pack-priv int | Returns: the size in bytes of this symbol table's BootstrapMethods attribute.Returns the size in bytes of this symbol table's BootstrapMethods attribute. |
| private void | copyBootstrapMethods(final ClassReader
the ClassReader whose bootstrap methods must be copied to initialize the
SymbolTable. classReader, final char[] a buffer used to read strings in the constant pool. charBuffer)Read the BootstrapMethods 'bootstrap_methods' array binary content and add them as entries of the SymbolTable. |
| private SymbolTable. | Returns: the list of entries which can potentially have the given hash code. The list is stored via theEntry#next field.a hashCode)Entry#hashCode value.Returns the list of entries which can potentially have the given hash code. |
| pack-priv String | Returns: the internal name of the class to which this symbol table belongs.Returns the internal name of the class to which this symbol table belongs. |
| pack-priv int | Returns: the number of items in this symbol table's constant_pool array (plus 1).Returns the number of items in this symbol table's constant_pool array (plus 1). |
| pack-priv int | Returns: the length in bytes of this symbol table's constant_pool array.Returns the length in bytes of this symbol table's constant_pool array. |
| pack-priv int | Returns: the major version of the class to which this symbol table belongs.Returns the major version of the class to which this symbol table belongs. |
| pack-priv ClassReader | Returns: the ClassReader from which this SymbolTable was constructed, or null if it was constructed from scratch.Returns the ClassReader from which this SymbolTable was constructed. |
| pack-priv Symbol | Returns: the type table element whose index is given.a type table index. typeIndex)Returns the type table element whose index is given. |
| private static int | |
| private static int | |
| private static int | |
| private static int | |
| private static int | |
| private static int | |
| private static int | |
| private static int | |
| private SymbolTable. | Returns: the given entryan Entry (which must not already be contained in entryentries).Puts the given entry in the |
| pack-priv void | putBootstrapMethods(final ByteVector
where the JVMS BootstrapMethods attribute must be put. output)Puts this symbol table's BootstrapMethods attribute in the given ByteVector. |
| pack-priv void | putConstantPool(final ByteVector
where the JVMS ClassFile's constant_pool array must be put. output)Puts this symbol table's constant_pool array in the given ByteVector, preceded by the constant_pool_count value. |
| pack-priv int | Returns: the constant pool index of a new or already existing Symbol with the given class name.a major ClassFile version number. majorVersion, final String an internal class name. className)Sets the major version and the name of the class to which this symbol table belongs. |