Package aQute.bnd.classfile
Class ConstantPool
java.lang.Object
aQute.bnd.classfile.ConstantPool
- Direct Known Subclasses:
MutableConstantPool
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
static class
static class
static class
static class
static interface
static class
static class
static class
static class
static class
static class
static class
static class
static interface
static class
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
static final int
(package private) final Object[]
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected <I> int
int
className
(int class_info_index) int
doubleInfo
(double constant) int
doubleInfo
(Double constant) int
dynamicInfo
(int bootstrap_method_attr_index, String name, String descriptor) <T> T
entry
(int index) private boolean
equalsAbstractDynamicInfo
(int bootstrap_method_attr_index, String name, String descriptor, ConstantPool.AbstractDynamicInfo abstractDynamicInfo) private boolean
equalsAbstractRefInfo
(String class_name, String name, String descriptor, ConstantPool.AbstractRefInfo refInfo) private boolean
equalsClassInfo
(String class_name, ConstantPool.ClassInfo classInfo) private static boolean
equalsDouble
(double a, double b) private static boolean
equalsFloat
(float a, float b) private static boolean
equalsInteger
(int a, int b) private static boolean
equalsLong
(long a, long b) private boolean
equalsMethodHandleInfo
(int reference_kind, String class_name, String name, String descriptor, ConstantPool.MethodHandleInfo methodHandleInfo) private boolean
equalsMethodTypeInfo
(String descriptor, ConstantPool.MethodTypeInfo methodTypeInfo) private boolean
equalsModuleInfo
(String module_name, ConstantPool.ModuleInfo moduleInfo) private boolean
equalsNameAndTypeInfo
(String name, String descriptor, ConstantPool.NameAndTypeInfo nameAndTypeInfo) private boolean
equalsPackageInfo
(String package_name, ConstantPool.PackageInfo packageInfo) private boolean
equalsStringInfo
(String string, ConstantPool.StringInfo stringInfo) int
fieldrefInfo
(String class_name, String name, String descriptor) int
floatInfo
(float constant) int
protected <I> int
int
integerInfo
(int constant) int
integerInfo
(Boolean constant) int
integerInfo
(Byte constant) int
integerInfo
(Character constant) int
integerInfo
(Integer constant) int
integerInfo
(Short constant) int
interfaceMethodrefInfo
(String class_name, String name, String descriptor) int
invokeDynamicInfo
(int bootstrap_method_attr_index, String name, String descriptor) int
longInfo
(long constant) int
int
methodHandleInfo
(int reference_kind, String class_name, String name, String descriptor, ConstantPool.RefInfoFunction refInfoFunction) int
methodrefInfo
(String class_name, String name, String descriptor) int
methodTypeInfo
(String descriptor) int
moduleInfo
(String module_name) moduleName
(int module_info_index) int
nameAndTypeInfo
(String name, String descriptor) int
packageInfo
(String package_name) packageName
(int package_info_index) static ConstantPool
(package private) static Double
(package private) static Float
(package private) static Integer
(package private) static Long
(package private) static String
int
size()
string
(int string_info_index) int
stringInfo
(String string) int
tag
(int index) toString()
utf8
(int utf8_index) int
void
write
(DataOutput out) (package private) static void
writeDoubleInfo
(DataOutput out, Double constant) (package private) static void
writeFloatInfo
(DataOutput out, Float constant) (package private) static void
writeIntegerInfo
(DataOutput out, Integer constant) (package private) static void
writeLongInfo
(DataOutput out, Long constant) (package private) static void
writeUtf8Info
(DataOutput out, String constant)
-
Field Details
-
CONSTANT_Utf8
public static final int CONSTANT_Utf8- See Also:
-
CONSTANT_Integer
public static final int CONSTANT_Integer- See Also:
-
CONSTANT_Float
public static final int CONSTANT_Float- See Also:
-
CONSTANT_Long
public static final int CONSTANT_Long- See Also:
-
CONSTANT_Double
public static final int CONSTANT_Double- See Also:
-
CONSTANT_Class
public static final int CONSTANT_Class- See Also:
-
CONSTANT_String
public static final int CONSTANT_String- See Also:
-
CONSTANT_Fieldref
public static final int CONSTANT_Fieldref- See Also:
-
CONSTANT_Methodref
public static final int CONSTANT_Methodref- See Also:
-
CONSTANT_InterfaceMethodref
public static final int CONSTANT_InterfaceMethodref- See Also:
-
CONSTANT_NameAndType
public static final int CONSTANT_NameAndType- See Also:
-
CONSTANT_MethodHandle
public static final int CONSTANT_MethodHandle- See Also:
-
CONSTANT_MethodType
public static final int CONSTANT_MethodType- See Also:
-
CONSTANT_Dynamic
public static final int CONSTANT_Dynamic- See Also:
-
CONSTANT_InvokeDynamic
public static final int CONSTANT_InvokeDynamic- See Also:
-
CONSTANT_Module
public static final int CONSTANT_Module- See Also:
-
CONSTANT_Package
public static final int CONSTANT_Package- See Also:
-
pool
-
-
Constructor Details
-
ConstantPool
-
-
Method Details
-
size
public int size() -
entry
public <T> T entry(int index) -
tag
public int tag(int index) -
utf8
-
className
-
moduleName
-
packageName
-
string
-
toString
-
read
- Throws:
IOException
-
readUtf8Info
- Throws:
IOException
-
writeUtf8Info
- Throws:
IOException
-
readIntegerInfo
- Throws:
IOException
-
writeIntegerInfo
- Throws:
IOException
-
readFloatInfo
- Throws:
IOException
-
writeFloatInfo
- Throws:
IOException
-
readLongInfo
- Throws:
IOException
-
writeLongInfo
- Throws:
IOException
-
readDoubleInfo
- Throws:
IOException
-
writeDoubleInfo
- Throws:
IOException
-
index
-
add
-
integerInfo
public int integerInfo(int constant) -
integerInfo
-
integerInfo
-
integerInfo
-
integerInfo
-
integerInfo
-
equalsInteger
private static boolean equalsInteger(int a, int b) -
longInfo
-
longInfo
public int longInfo(long constant) -
equalsLong
private static boolean equalsLong(long a, long b) -
floatInfo
-
floatInfo
public int floatInfo(float constant) -
equalsFloat
private static boolean equalsFloat(float a, float b) -
doubleInfo
-
doubleInfo
public int doubleInfo(double constant) -
equalsDouble
private static boolean equalsDouble(double a, double b) -
utf8Info
-
stringInfo
-
equalsStringInfo
-
moduleInfo
-
equalsModuleInfo
-
packageInfo
-
equalsPackageInfo
-
classInfo
-
equalsClassInfo
-
fieldrefInfo
-
equalsAbstractRefInfo
private boolean equalsAbstractRefInfo(String class_name, String name, String descriptor, ConstantPool.AbstractRefInfo refInfo) -
methodrefInfo
-
interfaceMethodrefInfo
-
nameAndTypeInfo
-
equalsNameAndTypeInfo
private boolean equalsNameAndTypeInfo(String name, String descriptor, ConstantPool.NameAndTypeInfo nameAndTypeInfo) -
methodHandleInfo
public int methodHandleInfo(int reference_kind, String class_name, String name, String descriptor, ConstantPool.RefInfoFunction refInfoFunction) -
equalsMethodHandleInfo
private boolean equalsMethodHandleInfo(int reference_kind, String class_name, String name, String descriptor, ConstantPool.MethodHandleInfo methodHandleInfo) -
methodTypeInfo
-
equalsMethodTypeInfo
-
dynamicInfo
-
equalsAbstractDynamicInfo
private boolean equalsAbstractDynamicInfo(int bootstrap_method_attr_index, String name, String descriptor, ConstantPool.AbstractDynamicInfo abstractDynamicInfo) -
invokeDynamicInfo
-
write
- Throws:
IOException
-