Interface IBinaryMethod
- All Superinterfaces:
IBinaryInfo,IElementInfo,IGenericMethod
- All Known Implementing Classes:
AnnotationMethodInfo,AnnotationMethodInfoWithAnnotations,CodeSnippetSkeleton.BinaryMethodSkeleton,MethodInfo,MethodInfoWithAnnotations
-
Method Summary
Modifier and TypeMethodDescriptionintAnswer the number of parameter annotations that can be retrieved usinggetParameterAnnotations(int, char[]).Answer the runtime visible and invisible annotations for this method or null if none.ReturnClassSignaturefor a ClassClass.char[][]Answer the resolved names of the exception types in the class file format as specified in section 4.2 of the Java 2 VM spec or null if the array is empty.char[]Answer the receiver's MethodSignature, which describes the type parameters, parameter types, return type, and exception types as specified in "4.7.9.1 Signatures" of the Java SE 8 VM spec.char[]Answer the receiver's method descriptor which describes the parameter and return types as specified in section 4.4.3 of the Java 2 VM spec.getParameterAnnotations(int index, char[] classFileName) Answer the annotations on theindexth parameter or null if nonedefault intAnswer the number of method parameters based on analysis of the method descriptor.char[]Answer the name of the method.longAnswer the tagbits set according to the bits for annotations.Answer the type annotations on this method.booleanisClinit()Answer whether the receiver represents a class initializer method.Methods inherited from interface org.aspectj.org.eclipse.jdt.internal.compiler.env.IGenericMethod
getArgumentNames, getModifiers, isConstructor
-
Method Details
-
getAnnotations
IBinaryAnnotation[] getAnnotations()Answer the runtime visible and invisible annotations for this method or null if none. -
getDefaultValue
Object getDefaultValue()ReturnClassSignaturefor a ClassClass. ReturnConstantfor compile-time constant of primitive type, as well as String literals. ReturnEnumConstantSignatureif value is an enum constant. ReturnIBinaryAnnotationfor annotation type. ReturnObject[] for array type.- Returns:
- default value of this annotation method
-
getExceptionTypeNames
char[][] getExceptionTypeNames()Answer the resolved names of the exception types in the class file format as specified in section 4.2 of the Java 2 VM spec or null if the array is empty. For example, java.lang.String is java/lang/String. -
getGenericSignature
char[] getGenericSignature()Answer the receiver's MethodSignature, which describes the type parameters, parameter types, return type, and exception types as specified in "4.7.9.1 Signatures" of the Java SE 8 VM spec. -
getMethodDescriptor
char[] getMethodDescriptor()Answer the receiver's method descriptor which describes the parameter and return types as specified in section 4.4.3 of the Java 2 VM spec. For example:- int foo(String) is (Ljava/lang/String;)I - Object[] foo(int) is (I)[Ljava/lang/Object;
-
getParameterAnnotations
Answer the annotations on theindexth parameter or null if none- Parameters:
index- the index of the parameter of interestclassFileName- (file) name of the declaring class for error reporting
-
getAnnotatedParametersCount
int getAnnotatedParametersCount()Answer the number of parameter annotations that can be retrieved usinggetParameterAnnotations(int, char[]).- Returns:
- one beyond the highest legal argument to
getParameterAnnotations(int, char[]).
-
getSelector
char[] getSelector()Answer the name of the method. For a constructor, answer<init> & <clinit>for a clinit method. -
getTagBits
long getTagBits()Answer the tagbits set according to the bits for annotations. -
isClinit
boolean isClinit()Answer whether the receiver represents a class initializer method. -
getTypeAnnotations
IBinaryTypeAnnotation[] getTypeAnnotations()Answer the type annotations on this method. -
getParameterCount
default int getParameterCount()Answer the number of method parameters based on analysis of the method descriptor.- Returns:
- the number of parameters or
-1if the descriptor was malformed.
-