Class FieldIdItem
java.lang.Object
com.android.dx.dex.file.Item
com.android.dx.dex.file.IndexedItem
com.android.dx.dex.file.IdItem
com.android.dx.dex.file.MemberIdItem
com.android.dx.dex.file.FieldIdItem
Representation of a field reference inside a Dalvik file.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddContents(DexFile file) Populates aDexFilewith items from within this instance.Gets the field constant.protected intgetTypoidIdx(DexFile file) Returns the index of the type-like thing associated with this item, in order that it may be written out.protected StringReturns the field name of the type-like thing associated with this item, for listing-generating purposes.itemType()Returns the item type for this instance.Methods inherited from class MemberIdItem
getRef, writeSize, writeToMethods inherited from class IdItem
getDefiningClassMethods inherited from class IndexedItem
getIndex, hasIndex, indexString, setIndex
-
Constructor Details
-
FieldIdItem
Constructs an instance.- Parameters:
field-non-null;the constant for the field
-
-
Method Details
-
itemType
-
addContents
Populates aDexFilewith items from within this instance. This will not add an item to the file for this instance itself (which should have been done by whatever refers to this instance).Note: Subclasses must override this to do something appropriate.
- Overrides:
addContentsin classMemberIdItem- Parameters:
file-non-null;the file to populate
-
getFieldRef
-
getTypoidIdx
Returns the index of the type-like thing associated with this item, in order that it may be written out. Subclasses must override this to get whatever it is they need to store.- Specified by:
getTypoidIdxin classMemberIdItem- Parameters:
file-non-null;the file being written- Returns:
- the index in question
-
getTypoidName
Returns the field name of the type-like thing associated with this item, for listing-generating purposes. Subclasses must override this.- Specified by:
getTypoidNamein classMemberIdItem- Returns:
non-null;the name in question
-