public final class StringIdItem extends IndexedItem implements java.lang.Comparable
| Constructor and Description |
|---|
StringIdItem(CstString value)
Constructs an instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addContents(DexFile file)
Populates a
DexFile with items from within this instance. |
int |
compareTo(java.lang.Object other) |
boolean |
equals(java.lang.Object other) |
StringDataItem |
getData()
Gets the associated data object for this instance, if known.
|
CstString |
getValue()
Gets the string value.
|
int |
hashCode() |
ItemType |
itemType()
Returns the item type for this instance.
|
int |
writeSize()
Gets the size of this instance when written, in bytes.
|
void |
writeTo(DexFile file,
AnnotatedOutput out)
Writes the representation of this instance to the given data section,
using the given
DexFile to look things up as needed. |
getIndex, hasIndex, indexString, setIndexpublic StringIdItem(CstString value)
value - non-null; the string valuepublic boolean equals(java.lang.Object other)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.Objectpublic int compareTo(java.lang.Object other)
compareTo in interface java.lang.Comparablepublic ItemType itemType()
public int writeSize()
public void addContents(DexFile file)
DexFile with 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.
addContents in class Itemfile - non-null; the file to populatepublic void writeTo(DexFile file, AnnotatedOutput out)
DexFile to look things up as needed.
If this instance keeps track of its offset, then this method will
note the written offset and will also throw an exception if this
instance has already been written.public CstString getValue()
non-null; the valuepublic StringDataItem getData()
null-ok; the associated data object or null
if not yet knownCopyright © 2020. All Rights Reserved.