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 DexBackedDexFile
dexFile
int
typeIndex
-
Constructor Summary
Constructors Constructor Description DexBackedTypeReference(DexBackedDexFile dexFile, int typeIndex)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getSize()
Calculate and return the private size of a type reference.java.lang.String
getType()
Gets the string representation of the referenced type.void
validateReference()
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:TypeReference
Gets 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.InvalidReferenceException
Description copied from interface:Reference
Verifies that this reference is valid.- Specified by:
validateReference
in interfaceReference
- Overrides:
validateReference
in classBaseReference
- Throws:
Reference.InvalidReferenceException
- If the reference is not valid.
-
-