com.android.dx.dex.file
Class MethodAnnotationStruct

java.lang.Object
  extended by com.android.dx.dex.file.MethodAnnotationStruct
All Implemented Interfaces:
ToHuman, Comparable<MethodAnnotationStruct>

public final class MethodAnnotationStruct
extends Object
implements ToHuman, Comparable<MethodAnnotationStruct>

Association of a method and its annotations.


Constructor Summary
MethodAnnotationStruct(CstMethodRef method, AnnotationSetItem annotations)
          Constructs an instance.
 
Method Summary
 void addContents(DexFile file)
          
 int compareTo(MethodAnnotationStruct other)
          
 boolean equals(Object other)
          
 Annotations getAnnotations()
          Gets the associated annotations.
 CstMethodRef getMethod()
          Gets the method this item is for.
 int hashCode()
          
 String toHuman()
          Return the "human" string form of this instance.
 void writeTo(DexFile file, AnnotatedOutput out)
          
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MethodAnnotationStruct

public MethodAnnotationStruct(CstMethodRef method,
                              AnnotationSetItem annotations)
Constructs an instance.

Parameters:
method - non-null; the method in question
annotations - non-null; the associated annotations
Method Detail

hashCode

public int hashCode()

Overrides:
hashCode in class Object

equals

public boolean equals(Object other)

Overrides:
equals in class Object

compareTo

public int compareTo(MethodAnnotationStruct other)

Specified by:
compareTo in interface Comparable<MethodAnnotationStruct>

addContents

public void addContents(DexFile file)


writeTo

public void writeTo(DexFile file,
                    AnnotatedOutput out)


toHuman

public String toHuman()
Return the "human" string form of this instance. This is generally less "debuggy" than toString().

Specified by:
toHuman in interface ToHuman
Returns:
non-null; the human string form

getMethod

public CstMethodRef getMethod()
Gets the method this item is for.

Returns:
non-null; the method

getAnnotations

public Annotations getAnnotations()
Gets the associated annotations.

Returns:
non-null; the annotations


Copyright © 2013. All Rights Reserved.