public class MethodMetadataReadingVisitor extends org.objectweb.asm.MethodVisitor implements MethodMetadata
org.springframework.core.type.MethodMetadata
interface.| 限定符和类型 | 字段和说明 |
|---|---|
protected int |
access |
protected LinkedMultiValueMap<String,AnnotationAttributes> |
attributesMap |
protected ClassLoader |
classLoader |
protected String |
declaringClassName |
protected Map<String,Set<String>> |
metaAnnotationMap |
protected Set<MethodMetadata> |
methodMetadataSet |
protected String |
methodName |
protected String |
returnTypeName |
| 构造器和说明 |
|---|
MethodMetadataReadingVisitor(String methodName,
int access,
String declaringClassName,
String returnTypeName,
ClassLoader classLoader,
Set<MethodMetadata> methodMetadataSet) |
| 限定符和类型 | 方法和说明 |
|---|---|
MultiValueMap<String,Object> |
getAllAnnotationAttributes(String annotationName)
Retrieve all attributes of all annotations of the given type, if any (i.e. if
defined on the underlying element, as direct annotation or meta-annotation).
|
MultiValueMap<String,Object> |
getAllAnnotationAttributes(String annotationName,
boolean classValuesAsString)
Retrieve all attributes of all annotations of the given type, if any (i.e. if
defined on the underlying element, as direct annotation or meta-annotation).
|
AnnotationAttributes |
getAnnotationAttributes(String annotationName)
Retrieve the attributes of the annotation of the given type, if any (i.e. if
defined on the underlying element, as direct annotation or meta-annotation),
also taking attribute overrides on composed annotations into account.
|
AnnotationAttributes |
getAnnotationAttributes(String annotationName,
boolean classValuesAsString)
Retrieve the attributes of the annotation of the given type, if any (i.e. if
defined on the underlying element, as direct annotation or meta-annotation),
also taking attribute overrides on composed annotations into account.
|
String |
getDeclaringClassName()
Return the fully-qualified name of the class that declares this method.
|
String |
getMethodName()
Return the name of the method.
|
String |
getReturnTypeName()
Return the fully-qualified name of this method's declared return type.
|
boolean |
isAbstract()
Return whether the underlying method is effectively abstract:
i.e. marked as abstract on a class or declared as a regular,
non-default method in an interface.
|
boolean |
isAnnotated(String annotationName)
Determine whether the underlying element has an annotation or meta-annotation
of the given type defined.
|
boolean |
isFinal()
Return whether the underlying method is marked as 'final'.
|
boolean |
isOverridable()
Return whether the underlying method is overridable,
i.e. not marked as static, final or private.
|
boolean |
isStatic()
Return whether the underlying method is declared as 'static'.
|
org.objectweb.asm.AnnotationVisitor |
visitAnnotation(String desc,
boolean visible) |
visitAnnotationDefault, visitAttribute, visitCode, visitEnd, visitFieldInsn, visitFrame, visitIincInsn, visitInsn, visitInsnAnnotation, visitIntInsn, visitInvokeDynamicInsn, visitJumpInsn, visitLabel, visitLdcInsn, visitLineNumber, visitLocalVariable, visitLocalVariableAnnotation, visitLookupSwitchInsn, visitMaxs, visitMethodInsn, visitMethodInsn, visitMultiANewArrayInsn, visitParameter, visitParameterAnnotation, visitTableSwitchInsn, visitTryCatchAnnotation, visitTryCatchBlock, visitTypeAnnotation, visitTypeInsn, visitVarInsnprotected final String methodName
protected final int access
protected final String declaringClassName
protected final String returnTypeName
protected final ClassLoader classLoader
protected final Set<MethodMetadata> methodMetadataSet
protected final LinkedMultiValueMap<String,AnnotationAttributes> attributesMap
public MethodMetadataReadingVisitor(String methodName, int access, String declaringClassName, String returnTypeName, ClassLoader classLoader, Set<MethodMetadata> methodMetadataSet)
public org.objectweb.asm.AnnotationVisitor visitAnnotation(String desc, boolean visible)
visitAnnotation 在类中 org.objectweb.asm.MethodVisitorpublic String getMethodName()
MethodMetadatagetMethodName 在接口中 MethodMetadatapublic boolean isAbstract()
MethodMetadataisAbstract 在接口中 MethodMetadatapublic boolean isStatic()
MethodMetadataisStatic 在接口中 MethodMetadatapublic boolean isFinal()
MethodMetadataisFinal 在接口中 MethodMetadatapublic boolean isOverridable()
MethodMetadataisOverridable 在接口中 MethodMetadatapublic boolean isAnnotated(String annotationName)
AnnotatedTypeMetadataIf this method returns true, then
AnnotatedTypeMetadata.getAnnotationAttributes(java.lang.String) will return a non-null Map.
isAnnotated 在接口中 AnnotatedTypeMetadataannotationName - the fully qualified class name of the annotation
type to look forpublic AnnotationAttributes getAnnotationAttributes(String annotationName)
AnnotatedTypeMetadatagetAnnotationAttributes 在接口中 AnnotatedTypeMetadataannotationName - the fully qualified class name of the annotation
type to look fornull if no matching annotation is defined.public AnnotationAttributes getAnnotationAttributes(String annotationName, boolean classValuesAsString)
AnnotatedTypeMetadatagetAnnotationAttributes 在接口中 AnnotatedTypeMetadataannotationName - the fully qualified class name of the annotation
type to look forclassValuesAsString - whether to convert class references to String
class names for exposure as values in the returned Map, instead of Class
references which might potentially have to be loaded firstnull if no matching annotation is defined.public MultiValueMap<String,Object> getAllAnnotationAttributes(String annotationName)
AnnotatedTypeMetadatagetAllAnnotationAttributes 在接口中 AnnotatedTypeMetadataannotationName - the fully qualified class name of the annotation
type to look fornull if no matching annotation is defined.AnnotatedTypeMetadata.getAllAnnotationAttributes(String, boolean)public MultiValueMap<String,Object> getAllAnnotationAttributes(String annotationName, boolean classValuesAsString)
AnnotatedTypeMetadatagetAllAnnotationAttributes 在接口中 AnnotatedTypeMetadataannotationName - the fully qualified class name of the annotation
type to look forclassValuesAsString - whether to convert class references to Stringnull if no matching annotation is defined.AnnotatedTypeMetadata.getAllAnnotationAttributes(String)public String getDeclaringClassName()
MethodMetadatagetDeclaringClassName 在接口中 MethodMetadatapublic String getReturnTypeName()
MethodMetadatagetReturnTypeName 在接口中 MethodMetadataCopyright © 2020. All rights reserved.