Package com.strobel.reflection
Class MemberInfo
java.lang.Object
com.strobel.reflection.MemberInfo
- All Implemented Interfaces:
AnnotatedElement
- Direct Known Subclasses:
FieldInfo
,MethodBase
,Type
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionabstract StringBuilder
abstract StringBuilder
abstract StringBuilder
abstract StringBuilder
abstract StringBuilder
abstract StringBuilder
static Annotation[]
boolean
<T extends Annotation>
TgetAnnotation
(Class<T> annotationClass) <T extends Annotation>
T[]getAnnotationsByType
(Class<T> annotationClass) Human-readable brief description of a type or member, which does not include information super types, thrown exceptions, or modifiers other than 'static'.<T extends Annotation>
TgetDeclaredAnnotation
(Class<T> annotationClass) <T extends Annotation>
T[]getDeclaredAnnotationsByType
(Class<T> annotationClass) abstract Type
<?> Human-readable full description of a type or member, which includes specification of super types (in brief format), thrown exceptions, and modifiers.Human-readable erased description of a type or member.Method that returns type erased signature of a type or member; suitable as non-generic signature some packages need.abstract MemberType
abstract int
abstract String
getName()
Type
<?> Method that returns full generic signature of a type or member.Human-readable simple description of a type or member, which does not include information super type or fully-qualified type names.int
hashCode()
protected void
Invalidate any cached type/member information.boolean
isAnnotationPresent
(Class<? extends Annotation> annotationClass) boolean
final boolean
isFinal()
final boolean
final boolean
final boolean
final boolean
final boolean
isPublic()
final boolean
isStatic()
toString()
-
Field Details
-
EMPTY_ANNOTATIONS
-
ENUM_MODIFIER
static final int ENUM_MODIFIER- See Also:
-
VARARGS_MODIFIER
static final int VARARGS_MODIFIER- See Also:
-
_signature
-
_erasedSignature
-
_description
-
_erasedDescription
-
_briefDescription
-
_simpleDescription
-
-
Constructor Details
-
MemberInfo
MemberInfo()
-
-
Method Details
-
emptyAnnotations
-
getMemberType
-
getName
-
getDeclaringType
-
getReflectedType
-
isFinal
public final boolean isFinal() -
isNonPublic
public final boolean isNonPublic() -
isPrivate
public final boolean isPrivate() -
isProtected
public final boolean isProtected() -
isPublic
public final boolean isPublic() -
isStatic
public final boolean isStatic() -
isPackagePrivate
public final boolean isPackagePrivate() -
getModifiers
public abstract int getModifiers() -
isAnnotationPresent
- Specified by:
isAnnotationPresent
in interfaceAnnotatedElement
-
getAnnotation
- Specified by:
getAnnotation
in interfaceAnnotatedElement
-
getAnnotations
- Specified by:
getAnnotations
in interfaceAnnotatedElement
-
getDeclaredAnnotations
- Specified by:
getDeclaredAnnotations
in interfaceAnnotatedElement
-
getDeclaredAnnotation
- Specified by:
getDeclaredAnnotation
in interfaceAnnotatedElement
-
getAnnotationsByType
- Specified by:
getAnnotationsByType
in interfaceAnnotatedElement
-
getDeclaredAnnotationsByType
- Specified by:
getDeclaredAnnotationsByType
in interfaceAnnotatedElement
-
equals
-
hashCode
public int hashCode() -
isEquivalentTo
-
getSignature
Method that returns full generic signature of a type or member. -
getErasedSignature
Method that returns type erased signature of a type or member; suitable as non-generic signature some packages need. -
getBriefDescription
Human-readable brief description of a type or member, which does not include information super types, thrown exceptions, or modifiers other than 'static'. -
getDescription
Human-readable full description of a type or member, which includes specification of super types (in brief format), thrown exceptions, and modifiers. -
getErasedDescription
Human-readable erased description of a type or member. -
getSimpleDescription
Human-readable simple description of a type or member, which does not include information super type or fully-qualified type names. -
toString
-
appendDescription
-
appendBriefDescription
-
appendErasedDescription
-
appendSignature
-
appendErasedSignature
-
appendSimpleDescription
-
appendGenericSignature
-
invalidateCaches
protected void invalidateCaches()Invalidate any cached type/member information. This is not guaranteed to be thread-safe, should only be called when a partially constructed type/member definition changes (e.g., a TypeBuilder, MethodBuilder, etc.).
-