Class ConstPool
java.lang.Object
org.jboss.classfilewriter.constpool.ConstPool
- All Implemented Interfaces:
WritableEntry
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static classprivate static final class -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate IntegerThe constant_pool_count field of the class file formatprivate intprivate final LinkedHashMap<Integer, ConstPoolEntry> private final Map<ConstPool.MemberInfo, Integer> private final Map<ConstPool.MemberInfo, Integer> private final Map<ConstPool.MemberInfo, Integer> private final Map<ConstPool.NameAndType, Integer> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionaddClassEntry(String className) Adds a CONSTANT_Class_info to the const pool.addDoubleEntry(double entry) addFieldEntry(String className, String fieldName, String fieldType) addFloatEntry(float entry) addIntegerEntry(int entry) addInterfaceMethodEntry(String className, String methodName, String descriptor) addLongEntry(long entry) addMethodEntry(String className, String methodName, String descriptor) addNameAndTypeEntry(String name, String type) addStringEntry(String string) Adds a CONSTANT_String_info to the const pool.addUtf8Entry(String entry) voidwrite(ByteArrayDataOutputStream stream)
-
Field Details
-
entries
-
utf8Locations
-
classLocations
-
stringLocations
-
nameAndTypeLocations
-
fieldLocations
-
methodLocations
-
interfaceMethodLocations
-
integerLocations
-
floatLocations
-
longLocations
-
doubleLocations
-
count
private int count -
constPoolSize
The constant_pool_count field of the class file format
-
-
Constructor Details
-
ConstPool
public ConstPool()
-
-
Method Details
-
addUtf8Entry
-
addClassEntry
Adds a CONSTANT_Class_info to the const pool. This must be in internal form -
addStringEntry
Adds a CONSTANT_String_info to the const pool. -
addIntegerEntry
-
addFloatEntry
-
addLongEntry
-
addDoubleEntry
-
addNameAndTypeEntry
-
addFieldEntry
-
addMethodEntry
-
addInterfaceMethodEntry
-
write
- Specified by:
writein interfaceWritableEntry- Throws:
IOException
-