Class DexBackedTypeReference
- java.lang.Object
-
- org.jf.dexlib2.base.reference.BaseReference
-
- org.jf.dexlib2.base.reference.BaseTypeReference
-
- org.jf.dexlib2.dexbacked.reference.DexBackedTypeReference
-
- All Implemented Interfaces:
java.lang.CharSequence,java.lang.Comparable<java.lang.CharSequence>,Reference,TypeReference
public class DexBackedTypeReference extends BaseTypeReference
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.jf.dexlib2.iface.reference.Reference
Reference.InvalidReferenceException
-
-
Field Summary
Fields Modifier and Type Field Description DexBackedDexFiledexFileinttypeIndex
-
Constructor Summary
Constructors Constructor Description DexBackedTypeReference(DexBackedDexFile dexFile, int typeIndex)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetSize()Calculate and return the private size of a type reference.java.lang.StringgetType()Gets the string representation of the referenced type.voidvalidateReference()Verifies that this reference is valid.-
Methods inherited from class org.jf.dexlib2.base.reference.BaseTypeReference
charAt, compareTo, equals, hashCode, length, subSequence, toString
-
-
-
-
Field Detail
-
dexFile
@Nonnull public final DexBackedDexFile dexFile
-
typeIndex
public final int typeIndex
-
-
Constructor Detail
-
DexBackedTypeReference
public DexBackedTypeReference(@Nonnull DexBackedDexFile dexFile, int typeIndex)
-
-
Method Detail
-
getType
@Nonnull public java.lang.String getType()
Description copied from interface:TypeReferenceGets the string representation of the referenced type. The returned string will be a TypeDescriptor, as defined in the dex file specification- Returns:
- The string representation of the referenced type.
-
getSize
public int getSize()
Calculate and return the private size of a type reference. Calculated as: descriptor_idx- Returns:
- size in bytes
-
validateReference
public void validateReference() throws Reference.InvalidReferenceExceptionDescription copied from interface:ReferenceVerifies that this reference is valid.- Specified by:
validateReferencein interfaceReference- Overrides:
validateReferencein classBaseReference- Throws:
Reference.InvalidReferenceException- If the reference is not valid.
-
-