java.lang.Object
de.grogra.reflect.MemberBase
de.grogra.reflect.FieldBase
- Direct Known Subclasses:
XField
-
Field Summary
Fields inherited from class de.grogra.reflect.MemberBase
annots, declaringType, descriptor, modifiers, name
Fields inherited from interface de.grogra.reflect.Field
FIELD_0, INTERFACE_MODIFIERS, MODIFIERS
Fields inherited from interface de.grogra.reflect.Member
ABSTRACT, ACCESS_MODIFIERS, ARRAY, BRIDGE, CONSTANT, FINAL, INTERFACE, JAVA_MODIFIERS, LOCAL_CLASS, MIN_UNUSED_MODIFIER, NATIVE, PRIVATE, PROTECTED, PUBLIC, STATIC, STRICT, SYNCHRONIZED, SYNTHETIC, TRANSIENT, VARARGS, VOLATILE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionboolean
getBoolean
(Object object) byte
char
Returns a descriptor for this member.double
float
int
long
short
final Type
getType()
void
setBoolean
(Object object, boolean value) void
void
void
void
void
void
void
void
toString()
Methods inherited from class de.grogra.reflect.MemberBase
getDeclaredAnnotation, getDeclaredAnnotationCount, getDeclaringType, getModifiers, getName, getSimpleName
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface de.grogra.reflect.Member
getDeclaredAnnotation, getDeclaredAnnotationCount, getDeclaringType, getModifiers, getName, getSimpleName
-
Field Details
-
type
-
-
Constructor Details
-
FieldBase
-
-
Method Details
-
getDescriptor
Description copied from interface:Member
Returns a descriptor for this member. Descriptors are constructed as follows:- For types, descriptors are defined as for the Java Virtual
Machine. For primitive types these are the single characters
'Z', 'B', 'S', 'C', 'I', 'J', 'F', 'D', 'V'
for
boolean
,byte
,short
,char
,int
,long
,float
,double
,void
. For array types, the descriptor is the character '[' plus the descriptor of its component type, e.g.,[[I
forint[][]
. For non-array reference types, the descriptor is the character 'L', followed by the binary name (seeType.getBinaryName()
) of the type, where '.' has to be replaced by '/', followed by ';', e.g.,Ljava/lang/Object;
. - For fields, the descriptor is the character 'f', followed by the
simple name of the field, followed by the character ';', followed
by the descriptor of the field's type. E.g.,
fout;Ljava/io/PrintStream;
for the fieldSystem.out
. - For methods and constructors, the descriptor is the character
'm', followed by the simple name of the method (which is
<init>
for constructors), followed by the characters ';' and '(', followed by the descriptors of the method's parameter types, followed by ')', followed by the descriptor of the return type. E.g.mprintln;(Ljava/lang/String;)V
for the methodPrintStream.println(String)
.
- Specified by:
getDescriptor
in interfaceMember
- Overrides:
getDescriptor
in classMemberBase
- Returns:
- the member's descriptor
- For types, descriptors are defined as for the Java Virtual
Machine. For primitive types these are the single characters
'Z', 'B', 'S', 'C', 'I', 'J', 'F', 'D', 'V'
for
-
getType
-
getBoolean
- Specified by:
getBoolean
in interfaceField
- Throws:
IllegalAccessException
-
setBoolean
- Specified by:
setBoolean
in interfaceField
- Throws:
IllegalAccessException
-
getByte
- Specified by:
getByte
in interfaceField
- Throws:
IllegalAccessException
-
setByte
- Specified by:
setByte
in interfaceField
- Throws:
IllegalAccessException
-
getShort
- Specified by:
getShort
in interfaceField
- Throws:
IllegalAccessException
-
setShort
- Specified by:
setShort
in interfaceField
- Throws:
IllegalAccessException
-
getChar
- Specified by:
getChar
in interfaceField
- Throws:
IllegalAccessException
-
setChar
- Specified by:
setChar
in interfaceField
- Throws:
IllegalAccessException
-
getInt
- Specified by:
getInt
in interfaceField
- Throws:
IllegalAccessException
-
setInt
- Specified by:
setInt
in interfaceField
- Throws:
IllegalAccessException
-
getLong
- Specified by:
getLong
in interfaceField
- Throws:
IllegalAccessException
-
setLong
- Specified by:
setLong
in interfaceField
- Throws:
IllegalAccessException
-
getFloat
- Specified by:
getFloat
in interfaceField
- Throws:
IllegalAccessException
-
setFloat
- Specified by:
setFloat
in interfaceField
- Throws:
IllegalAccessException
-
getDouble
- Specified by:
getDouble
in interfaceField
- Throws:
IllegalAccessException
-
setDouble
- Specified by:
setDouble
in interfaceField
- Throws:
IllegalAccessException
-
getObject
- Specified by:
getObject
in interfaceField
- Throws:
IllegalAccessException
-
setObject
- Specified by:
setObject
in interfaceField
- Throws:
IllegalAccessException
-
toString
- Overrides:
toString
in classMemberBase
-