public interface XMethod extends ClassMember, AnnotatedObject, ComparableMethod
If the resolved() method returns true, then any information queried from this object can be assumed to be accurate. If the resolved() method returns false, then FindBugs can't find the method and any information other than name/signature/etc. cannot be trusted.
Modifier and Type | Method and Description |
---|---|
void |
addAnnotation(AnnotationValue annotationValue)
Destructively add an annotation.
|
void |
addParameterAnnotation(int param,
AnnotationValue annotationValue)
Destructively add a parameter annotation.
|
XMethod |
bridgeFrom() |
XMethod |
bridgeTo()
If nonnull, then this method is a synthetic method that overrides a
method in a superclass.
|
FieldDescriptor |
getAccessMethodForField() |
MethodDescriptor |
getAccessMethodForMethod() |
AnnotationValue |
getAnnotation(ClassDescriptor desc)
Get the AnnotationValue of annotation applied directly to the method.
|
java.util.Collection<ClassDescriptor> |
getAnnotationDescriptors()
Get ClassDescriptors (annotation classes) of annotations applied directly
to this method.
|
java.util.Collection<AnnotationValue> |
getAnnotations()
Get collection of all AnnotationValues applied directly to the method.
|
MethodDescriptor |
getMethodDescriptor() |
int |
getNumParams() |
AnnotationValue |
getParameterAnnotation(int param,
ClassDescriptor desc)
Get the AnnotationValue of annotation applied directly to given
parameter.
|
java.util.Collection<ClassDescriptor> |
getParameterAnnotationDescriptors(int param)
Get ClassDescriptors (annotation classes) of annotations applied directly
to this method's parameters.
|
java.util.Collection<AnnotationValue> |
getParameterAnnotations(int param)
Get collection of all AnnotationValues applied directly to given
parameter.
|
java.lang.String[] |
getThrownExceptions() |
boolean |
hasParameterAnnotations() |
boolean |
isAbstract() |
boolean |
isBridge()
Is this a bridge method?
|
boolean |
isIdentity()
Is this an identity method
|
boolean |
isNative() |
boolean |
isReturnTypeReferenceType() |
boolean |
isStub() |
boolean |
isSynchronized() |
boolean |
isUnconditionalThrower() |
boolean |
isUnsupported() |
boolean |
isVarArgs() |
boolean |
isVariableSynthetic(int param)
Is the variable synthetic?
|
XMethod |
resolveAccessMethodForMethod() |
boolean |
usesConcurrency() |
boolean |
usesInvokeDynamic() |
getClassName, getName, getPackageName, getSignature, getSourceSignature, isResolved
getAccessFlags, getClassDescriptor, isDeprecated, isFinal, isPrivate, isProtected, isPublic, isStatic, isSynthetic
getClassDescriptor, isStatic
getClassDescriptor, getContainingScope, getElementType, isSynthetic
boolean isNative()
boolean isAbstract()
boolean isSynchronized()
int getNumParams()
MethodDescriptor getMethodDescriptor()
java.lang.String[] getThrownExceptions()
boolean isUnconditionalThrower()
boolean usesConcurrency()
boolean isStub()
boolean isIdentity()
@CheckForNull XMethod bridgeTo()
@CheckForNull XMethod bridgeFrom()
@CheckForNull MethodDescriptor getAccessMethodForMethod()
@CheckForNull FieldDescriptor getAccessMethodForField()
XMethod resolveAccessMethodForMethod()
boolean isUnsupported()
boolean isVarArgs()
boolean isReturnTypeReferenceType()
boolean isBridge()
java.util.Collection<ClassDescriptor> getParameterAnnotationDescriptors(int param)
param
- parameter number (0 for first parameter)@CheckForNull AnnotationValue getParameterAnnotation(int param, ClassDescriptor desc)
param
- parameter number (0 for first parameter)desc
- ClassDescriptor of the annotation classjava.util.Collection<AnnotationValue> getParameterAnnotations(int param)
param
- parameter number (0 for first parameter)boolean hasParameterAnnotations()
java.util.Collection<ClassDescriptor> getAnnotationDescriptors()
getAnnotationDescriptors
in interface AnnotatedObject
AnnotationValue getAnnotation(ClassDescriptor desc)
getAnnotation
in interface AnnotatedObject
desc
- ClassDescriptor of the annotation classjava.util.Collection<AnnotationValue> getAnnotations()
getAnnotations
in interface AnnotatedObject
void addParameterAnnotation(int param, AnnotationValue annotationValue)
param
- parameter (0 == first parameter)annotationValue
- an AnnotationValue representing a parameter annotationboolean isVariableSynthetic(int param)
void addAnnotation(AnnotationValue annotationValue)
annotationValue
- an AnnotationValue representing a method annotationboolean usesInvokeDynamic()
FindBugs™ is licenced under the LGPL. Copyright © 2006 University of Maryland.