Class AnnotationUtils
java.lang.Object
com.android.dx.dex.file.AnnotationUtils
Utility class for dealing with annotations.
-
Method Summary
Modifier and TypeMethodDescriptionstatic AnnotationmakeAnnotationDefault(Annotation defaults) Constructs a standardAnnotationDefaultannotation.static AnnotationmakeEnclosingClass(CstType clazz) Constructs a standardEnclosingClassannotation.static AnnotationmakeEnclosingMethod(CstMethodRef method) Constructs a standardEnclosingMethodannotation.static AnnotationmakeInnerClass(CstString name, int accessFlags) Constructs a standardInnerClassannotation.static AnnotationmakeMemberClasses(TypeList types) Constructs a standardMemberClassesannotation.static AnnotationmakeSignature(CstString signature) Constructs a standardSignatureannotation.static AnnotationmakeSourceDebugExtension(CstString smapString) Constructs a standardSourceDebugExtensionannotation.static AnnotationmakeThrows(TypeList types) Constructs a standardThrowsannotation.
-
Method Details
-
makeAnnotationDefault
Constructs a standardAnnotationDefaultannotation.- Parameters:
defaults-non-null;the defaults, itself as an annotation- Returns:
non-null;the constructed annotation
-
makeEnclosingClass
Constructs a standardEnclosingClassannotation.- Parameters:
clazz-non-null;the enclosing class- Returns:
non-null;the annotation
-
makeEnclosingMethod
Constructs a standardEnclosingMethodannotation.- Parameters:
method-non-null;the enclosing method- Returns:
non-null;the annotation
-
makeInnerClass
Constructs a standardInnerClassannotation.- Parameters:
name-null-ok;the original name of the class, ornullto represent an anonymous classaccessFlags- the original access flags- Returns:
non-null;the annotation
-
makeMemberClasses
Constructs a standardMemberClassesannotation.- Parameters:
types-non-null;the list of (the types of) the member classes- Returns:
non-null;the annotation
-
makeSignature
Constructs a standardSignatureannotation.- Parameters:
signature-non-null;the signature string- Returns:
non-null;the annotation
-
makeSourceDebugExtension
Constructs a standardSourceDebugExtensionannotation.- Parameters:
smapString-non-null;the SMAP string associated with- Returns:
non-null;the annotation
-
makeThrows
Constructs a standardThrowsannotation.- Parameters:
types-non-null;the list of thrown types- Returns:
non-null;the annotation
-