类 ProgramClass
java.lang.Object
proguard.util.SimpleProcessable
proguard.util.SimpleFeatureNamedProcessable
proguard.classfile.ProgramClass
- 所有已实现的接口:
Serializable,Clazz,FeatureNamed,Processable
This
Clazz is a complete representation of the data in a Java class.- 另请参阅:
-
字段概要
字段修饰符和类型字段说明Constant[]intClazz[]An extra field pointing to the subclasses of this class.intintintintint[]intintintintint从类继承的字段 proguard.util.SimpleFeatureNamedProcessable
extraFeatureNames, featureName从类继承的字段 proguard.util.SimpleProcessable
processingFlags, processingInfo -
构造器概要
构造器构造器说明Creates an uninitialized ProgramClass.ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass) Creates an initialized ProgramClass without fields, methods, attributes, or subclasses.ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass, int u2interfacesCount, int[] u2interfaces, int u2fieldsCount, ProgramField[] fields, int u2methodsCount, ProgramMethod[] methods, int u2attributesCount, Attribute[] attributes, int subClassCount, Clazz[] subClasses) Creates an initialized ProgramClass.ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass, int u2interfacesCount, int[] u2interfaces, int u2fieldsCount, ProgramField[] fields, int u2methodsCount, ProgramMethod[] methods, int u2attributesCount, Attribute[] attributes, int subClassCount, Clazz[] subClasses, String featureName, int processingFlags, Object processingInfo) Creates an initialized ProgramClass.ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass, String featureName, int processingFlags, Object processingInfo) Creates an initialized ProgramClass without fields, methods, attributes, or subclasses. -
方法概要
修饰符和类型方法说明voidaccept(ClassVisitor classVisitor) Accepts the given class visitor.voidaddSubClass(Clazz clazz) Notifies this Clazz that it is being subclassed by another class.voidattributeAccept(String name, AttributeVisitor attributeVisitor) Lets the given attribute info visitor visit the specified attribute.voidattributesAccept(AttributeVisitor attributeVisitor) Lets the given attribute info visitor visit all attributes of this class.voidconstantPoolEntriesAccept(ConstantVisitor constantVisitor) Lets the given constant pool entry visitor visit all constant pool entries of this class.voidconstantPoolEntryAccept(int index, ConstantVisitor constantVisitor) Lets the given constant pool entry visitor visit the constant pool entry at the specified index.booleanReturns whether this class extends the specified class.booleanReturns whether this class extends the given class.booleanextendsOrImplements(String className) Returns whether this class implements the specified class.booleanextendsOrImplements(Clazz clazz) Returns whether this class implements the given class.voidfieldAccept(String name, String descriptor, MemberVisitor memberVisitor) Lets the given member info visitor visit the specified field.voidfieldsAccept(MemberVisitor memberVisitor) Lets the given member info visitor visit all fields of this class.Returns the field with the given name and descriptor.findMethod(String name, String descriptor) Returns the method with the given name and descriptor.intReturns the access flags of this class.getClassName(int constantIndex) Returns the class name of ClassConstant at the specified index.getConstant(int constantIndex) Returns the Constant at the given index in the constant pool.getInterface(int index) Returns the interface at the given index.intReturns the number of interfaces that this class implements.getInterfaceName(int index) Returns the full internal name of the interface at the given index of this class.getModuleName(int constantIndex) Returns the name of the ModuleConstant at the specified index.getName()Returns the full internal name of this class.getName(int constantIndex) Returns the name of the NameAndTypeConstant at the specified index.getPackageName(int constantIndex) Returns the name of the PackageConstant at the specified index.getRefClassName(int constantIndex) Returns the class name of the RefConstant at the specified index.getReferencedClass(int constantIndex) Returns theClassConstant.referencedClassat the specified index.getRefName(int constantIndex) Returns the name of the RefConstant at the specified index.getRefType(int constantIndex) Returns the type of the RefConstant at the specified index.getString(int constantIndex) Returns the String value of the Utf8Constant at the specified index.getStringString(int constantIndex) Returns the String value of the StringConstant at the specified index.Returns the super class of this class.Returns the full internal name of the super class of this class, or null if this class represents java.lang.Object.intgetTag(int constantIndex) Returns the tag value of the Constant at the specified index.getType(int constantIndex) Returns the type of the NameAndTypeConstant at the specified index.voidhierarchyAccept(boolean visitThisClass, boolean visitSuperClass, boolean visitInterfaces, boolean visitSubclasses, ClassVisitor classVisitor) Accepts the given class visitor in the class hierarchy.voidinterfaceConstantsAccept(ConstantVisitor constantVisitor) Lets the given constant pool entry visitor visit the class constant pool entries for all interfaces of this class.voidkotlinMetadataAccept(KotlinMetadataVisitor kotlinMetadataVisitor) Lets the given Kotlin metadata visitor visit the metadata of this class.booleanmayHaveImplementations(Method method) Returns whether the given method may possibly have implementing or overriding methods down the class hierarchy.voidmethodAccept(String name, String descriptor, MemberVisitor memberVisitor) Lets the given member info visitor visit the specified method.voidmethodsAccept(MemberVisitor memberVisitor) Lets the given member info visitor visit all methods of this class.voidremoveSubClass(Clazz clazz) Notifies this Clazz that it is no longer being subclassed by another class.voidsubclassesAccept(ClassVisitor classVisitor) Lets the given class visitor visit all known subclasses.voidsuperClassConstantAccept(ConstantVisitor constantVisitor) Lets the given constant pool entry visitor visit the class constant pool entry of the super class of this class, if there is one.voidthisClassConstantAccept(ConstantVisitor constantVisitor) Lets the given constant pool entry visitor visit the class constant pool entry of this class.toString()从类继承的方法 proguard.util.SimpleFeatureNamedProcessable
addExtraFeatureName, getExtraFeatureNames, getFeatureName, isInFeature, setFeatureName从类继承的方法 proguard.util.SimpleProcessable
addProcessingFlags, getProcessingFlags, getProcessingInfo, hasProcessingFlags, removeProcessingFlags, setProcessingFlags, setProcessingInfo从类继承的方法 java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait从接口继承的方法 proguard.util.FeatureNamed
addExtraFeatureName, getExtraFeatureNames, getFeatureName, isInFeature, setFeatureName从接口继承的方法 proguard.util.Processable
accept, addProcessingFlags, getProcessingFlags, getProcessingInfo, hasProcessingFlags, removeProcessingFlags, setProcessingFlags, setProcessingInfo
-
字段详细资料
-
u4version
public int u4version -
u2constantPoolCount
public int u2constantPoolCount -
constantPool
-
u2accessFlags
public int u2accessFlags -
u2thisClass
public int u2thisClass -
u2superClass
public int u2superClass -
u2interfacesCount
public int u2interfacesCount -
u2interfaces
public int[] u2interfaces -
u2fieldsCount
public int u2fieldsCount -
fields
-
u2methodsCount
public int u2methodsCount -
methods
-
u2attributesCount
public int u2attributesCount -
attributes
-
kotlinMetadata
-
subClasses
An extra field pointing to the subclasses of this class. This field is typically filled out by theClassSubHierarchyInitializer. -
subClassCount
public int subClassCount
-
-
构造器详细资料
-
ProgramClass
public ProgramClass()Creates an uninitialized ProgramClass. -
ProgramClass
public ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass) Creates an initialized ProgramClass without fields, methods, attributes, or subclasses. -
ProgramClass
public ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass, String featureName, int processingFlags, Object processingInfo) Creates an initialized ProgramClass without fields, methods, attributes, or subclasses. -
ProgramClass
public ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass, int u2interfacesCount, int[] u2interfaces, int u2fieldsCount, ProgramField[] fields, int u2methodsCount, ProgramMethod[] methods, int u2attributesCount, Attribute[] attributes, int subClassCount, Clazz[] subClasses) Creates an initialized ProgramClass. -
ProgramClass
public ProgramClass(int u4version, int u2constantPoolCount, Constant[] constantPool, int u2accessFlags, int u2thisClass, int u2superClass, int u2interfacesCount, int[] u2interfaces, int u2fieldsCount, ProgramField[] fields, int u2methodsCount, ProgramMethod[] methods, int u2attributesCount, Attribute[] attributes, int subClassCount, Clazz[] subClasses, String featureName, int processingFlags, Object processingInfo) Creates an initialized ProgramClass.
-
-
方法详细资料
-
getConstant
Returns the Constant at the given index in the constant pool. -
getAccessFlags
public int getAccessFlags()从接口复制的说明:ClazzReturns the access flags of this class.- 指定者:
getAccessFlags在接口中Clazz- 另请参阅:
-
getName
从接口复制的说明:ClazzReturns the full internal name of this class. -
getSuperName
从接口复制的说明:ClazzReturns the full internal name of the super class of this class, or null if this class represents java.lang.Object.- 指定者:
getSuperName在接口中Clazz
-
getInterfaceCount
public int getInterfaceCount()从接口复制的说明:ClazzReturns the number of interfaces that this class implements.- 指定者:
getInterfaceCount在接口中Clazz
-
getInterfaceName
从接口复制的说明:ClazzReturns the full internal name of the interface at the given index of this class.- 指定者:
getInterfaceName在接口中Clazz
-
getTag
public int getTag(int constantIndex) 从接口复制的说明:ClazzReturns the tag value of the Constant at the specified index. -
getString
从接口复制的说明:ClazzReturns the String value of the Utf8Constant at the specified index. -
getStringString
从接口复制的说明:ClazzReturns the String value of the StringConstant at the specified index.- 指定者:
getStringString在接口中Clazz
-
getClassName
从接口复制的说明:ClazzReturns the class name of ClassConstant at the specified index.- 指定者:
getClassName在接口中Clazz
-
getReferencedClass
从接口复制的说明:ClazzReturns theClassConstant.referencedClassat the specified index.- 指定者:
getReferencedClass在接口中Clazz
-
getName
从接口复制的说明:ClazzReturns the name of the NameAndTypeConstant at the specified index. -
getType
从接口复制的说明:ClazzReturns the type of the NameAndTypeConstant at the specified index. -
getRefClassName
从接口复制的说明:ClazzReturns the class name of the RefConstant at the specified index.- 指定者:
getRefClassName在接口中Clazz
-
getRefName
从接口复制的说明:ClazzReturns the name of the RefConstant at the specified index.- 指定者:
getRefName在接口中Clazz
-
getRefType
从接口复制的说明:ClazzReturns the type of the RefConstant at the specified index.- 指定者:
getRefType在接口中Clazz
-
getModuleName
从接口复制的说明:ClazzReturns the name of the ModuleConstant at the specified index.- 指定者:
getModuleName在接口中Clazz
-
getPackageName
从接口复制的说明:ClazzReturns the name of the PackageConstant at the specified index.- 指定者:
getPackageName在接口中Clazz
-
addSubClass
从接口复制的说明:ClazzNotifies this Clazz that it is being subclassed by another class.- 指定者:
addSubClass在接口中Clazz
-
removeSubClass
从接口复制的说明:ClazzNotifies this Clazz that it is no longer being subclassed by another class.- 指定者:
removeSubClass在接口中Clazz
-
getSuperClass
从接口复制的说明:ClazzReturns the super class of this class.- 指定者:
getSuperClass在接口中Clazz
-
getInterface
从接口复制的说明:ClazzReturns the interface at the given index.- 指定者:
getInterface在接口中Clazz
-
extends_
从接口复制的说明:ClazzReturns whether this class extends the given class. A class is always considered to extend itself. Interfaces are considered to only extend the root Object class. -
extends_
从接口复制的说明:ClazzReturns whether this class extends the specified class. A class is always considered to extend itself. Interfaces are considered to only extend the root Object class. -
extendsOrImplements
从接口复制的说明:ClazzReturns whether this class implements the given class. A class is always considered to implement itself. Interfaces are considered to implement all their superinterfaces.- 指定者:
extendsOrImplements在接口中Clazz
-
extendsOrImplements
从接口复制的说明:ClazzReturns whether this class implements the specified class. A class is always considered to implement itself. Interfaces are considered to implement all their superinterfaces.- 指定者:
extendsOrImplements在接口中Clazz
-
findField
从接口复制的说明:ClazzReturns the field with the given name and descriptor. -
findMethod
从接口复制的说明:ClazzReturns the method with the given name and descriptor.- 指定者:
findMethod在接口中Clazz- 参数:
name- the method name, or null if it is irrelevant.descriptor- the method descriptor, or null if it is irrelevant.- 返回:
- the first matching method, or null there is no matching method.
-
accept
从接口复制的说明:ClazzAccepts the given class visitor. -
hierarchyAccept
public void hierarchyAccept(boolean visitThisClass, boolean visitSuperClass, boolean visitInterfaces, boolean visitSubclasses, ClassVisitor classVisitor) 从接口复制的说明:ClazzAccepts the given class visitor in the class hierarchy.- 指定者:
hierarchyAccept在接口中Clazz- 参数:
visitThisClass- specifies whether to visit this class.visitSuperClass- specifies whether to visit the super classes.visitInterfaces- specifies whether to visit the interfaces.visitSubclasses- specifies whether to visit the subclasses.classVisitor- theClassVisitorthat will visit the class hierarchy.
-
subclassesAccept
从接口复制的说明:ClazzLets the given class visitor visit all known subclasses.- 指定者:
subclassesAccept在接口中Clazz- 参数:
classVisitor- theClassVisitorthat will visit the subclasses.
-
constantPoolEntriesAccept
从接口复制的说明:ClazzLets the given constant pool entry visitor visit all constant pool entries of this class.- 指定者:
constantPoolEntriesAccept在接口中Clazz
-
constantPoolEntryAccept
从接口复制的说明:ClazzLets the given constant pool entry visitor visit the constant pool entry at the specified index.- 指定者:
constantPoolEntryAccept在接口中Clazz
-
thisClassConstantAccept
从接口复制的说明:ClazzLets the given constant pool entry visitor visit the class constant pool entry of this class.- 指定者:
thisClassConstantAccept在接口中Clazz
-
superClassConstantAccept
从接口复制的说明:ClazzLets the given constant pool entry visitor visit the class constant pool entry of the super class of this class, if there is one.- 指定者:
superClassConstantAccept在接口中Clazz
-
interfaceConstantsAccept
从接口复制的说明:ClazzLets the given constant pool entry visitor visit the class constant pool entries for all interfaces of this class.- 指定者:
interfaceConstantsAccept在接口中Clazz
-
fieldsAccept
从接口复制的说明:ClazzLets the given member info visitor visit all fields of this class.- 指定者:
fieldsAccept在接口中Clazz
-
fieldAccept
从接口复制的说明:ClazzLets the given member info visitor visit the specified field.- 指定者:
fieldAccept在接口中Clazz
-
methodsAccept
从接口复制的说明:ClazzLets the given member info visitor visit all methods of this class.- 指定者:
methodsAccept在接口中Clazz
-
methodAccept
从接口复制的说明:ClazzLets the given member info visitor visit the specified method.- 指定者:
methodAccept在接口中Clazz
-
mayHaveImplementations
从接口复制的说明:ClazzReturns whether the given method may possibly have implementing or overriding methods down the class hierarchy. This can only be true if the class is not final, and the method is not private, static, or final, or a constructor.- 指定者:
mayHaveImplementations在接口中Clazz- 参数:
method- the method that may have implementations.- 返回:
- whether it may have implementations.
-
attributesAccept
从接口复制的说明:ClazzLets the given attribute info visitor visit all attributes of this class.- 指定者:
attributesAccept在接口中Clazz
-
attributeAccept
从接口复制的说明:ClazzLets the given attribute info visitor visit the specified attribute.- 指定者:
attributeAccept在接口中Clazz
-
kotlinMetadataAccept
从接口复制的说明:ClazzLets the given Kotlin metadata visitor visit the metadata of this class.- 指定者:
kotlinMetadataAccept在接口中Clazz
-
toString
-