| Modifier and Type | Class and Description |
|---|---|
| private static class | AnnotationItem.
Comparator that sorts (outer) instances by type id index. |
| Modifier and Type | Field and Description |
|---|---|
| private static final int | ALIGNMENT
the required alignment for instances of this class |
| private final Annotation | annotation
|
| private byte[] | encodedForm
|
| private TypeIdItem | type
|
| private static final AnnotationItem. | TYPE_ID_SORTER
|
| private static final int | VISIBILITY_BUILD
annotation visibility constant: visible at build time only |
| private static final int | VISIBILITY_RUNTIME
annotation visibility constant: visible at runtime |
| private static final int | VISIBILITY_SYSTEM
annotation visibility constant: visible at runtime only to system |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | addContents(DexFile
non-null; the file to populateImplements abstract org. DexFile with items from within this instance.
|
| public void | annotateTo(AnnotatedOutput
non-null; where to output tonon-null; prefix for each line of outputWrite a (listing file) annotation for this instance to the given output, that consumes no bytes of output. |
| protected int | compareTo0(OffsettedItem
non-null; instance to compare toOverrides org. |
| public int | |
| public ItemType | itemType()
Implements abstract org. |
| protected void | place0(Section
non-null; the section this instance has been added to>= 0; the offset from the start of the
section where this instance was placedOverrides org. |
| public static void | sortByTypeIdIndex(AnnotationItem[]
non-null; array to sortSorts an array of instances, in place, by type id index, ignoring all other aspects of the elements. |
| public String | toHuman()
Implements abstract org. |
| protected void | writeTo0(DexFile
non-null; the file to use for referencenon-null; where to write toImplements abstract org. |
| ALIGNMENT | back to summary |
|---|---|
| private static final int ALIGNMENT the required alignment for instances of this class | |
| annotation | back to summary |
|---|---|
| private final Annotation annotation
| |
| encodedForm | back to summary |
|---|---|
| private byte[] encodedForm
| |
| type | back to summary |
|---|---|
| private TypeIdItem type
| |
| TYPE_ID_SORTER | back to summary |
|---|---|
| private static final AnnotationItem.
| |
| VISIBILITY_BUILD | back to summary |
|---|---|
| private static final int VISIBILITY_BUILD annotation visibility constant: visible at build time only | |
| VISIBILITY_RUNTIME | back to summary |
|---|---|
| private static final int VISIBILITY_RUNTIME annotation visibility constant: visible at runtime | |
| VISIBILITY_SYSTEM | back to summary |
|---|---|
| private static final int VISIBILITY_SYSTEM annotation visibility constant: visible at runtime only to system | |
| AnnotationItem | back to summary |
|---|---|
| public AnnotationItem(Annotation annotation) Constructs an instance.
| |
| addContents | back to summary |
|---|---|
| public void addContents(DexFile file) Implements abstract org. Doc from org. Populates a Note Subclasses must override this to do something appropriate.
| |
| annotateTo | back to summary |
|---|---|
| public void annotateTo(AnnotatedOutput out, String prefix) Write a (listing file) annotation for this instance to the given output, that consumes no bytes of output. This is for annotating a reference to this instance at the point of the reference.
| |
| compareTo0 | back to summary |
|---|---|
| protected int compareTo0(OffsettedItem other) Overrides org. Doc from org. Compares this instance to another which is guaranteed to be of the same class. The default implementation of this method is to throw an exception (unsupported operation). If a particular class needs to actually sort, then it should override this method.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Doc from java. Returns a hash code value for this object. This method is
supported for the benefit of hash tables such as those provided by
The general contract of
| |
| itemType | back to summary |
|---|---|
| public ItemType itemType() Implements abstract org. Doc from org. Returns the item type for this instance. | |
| place0 | back to summary |
|---|---|
| protected void place0(Section addedTo, int offset) Overrides org. Doc from org. Does additional work required when placing an instance. The default implementation of this method is a no-op. If a particular class needs to do something special, then it should override this method. In particular, if this instance did not know its write size up-front, then this method is responsible for setting it. | |
| sortByTypeIdIndex | back to summary |
|---|---|
| public static void sortByTypeIdIndex(AnnotationItem[] array) Sorts an array of instances, in place, by type id index, ignoring all other aspects of the elements. This is only valid to use after type id indices are known.
| |
| toHuman | back to summary |
|---|---|
| public String toHuman() Implements abstract org. Doc from org. Gets a short human-readable string representing this instance. | |
| writeTo0 | back to summary |
|---|---|
| protected void writeTo0(DexFile file, AnnotatedOutput out) Implements abstract org. Doc from org. Performs the actual write of the contents of this instance to
the given data section. This is called by
| |
| Access | Constructor and Description |
|---|---|
| private |
| Modifier and Type | Method and Description |
|---|---|
| public int | compare(AnnotationItem
the first object to be compared. item1, AnnotationItem the second object to be compared. item2)Implements java. |
| TypeIdSorter | back to summary |
|---|---|
| private TypeIdSorter() | |
| compare | back to summary |
|---|---|
| public int compare(AnnotationItem item1, AnnotationItem item2) Implements java. Doc from java. Compares its two arguments for order. Returns a negative integer, zero, or a positive integer as the first argument is less than, equal to, or greater than the second.
The implementor must ensure that
The implementor must also ensure that the relation is transitive:
Finally, the implementor must ensure that
| |