Modifier and Type | Field and Description |
---|---|
private Property |
delegate |
private java.lang.reflect.Field |
field |
private boolean |
filler |
private static java.util.logging.Logger |
log |
protected java.lang.Class<?>[] |
parameters |
private java.lang.reflect.Method |
read |
private java.lang.String |
readMethod |
protected java.lang.Class<?> |
targetType |
private java.lang.reflect.Method |
write |
private java.lang.String |
writeMethod |
Constructor and Description |
---|
PropertySubstitute(java.lang.String name,
java.lang.Class<?> type,
java.lang.Class<?>... params) |
PropertySubstitute(java.lang.String name,
java.lang.Class<?> type,
java.lang.String readMethod,
java.lang.String writeMethod,
java.lang.Class<?>... params) |
Modifier and Type | Method and Description |
---|---|
private java.lang.reflect.Method |
discoverMethod(java.lang.Class<?> type,
java.lang.String name,
java.lang.Class<?>... params) |
java.lang.Object |
get(java.lang.Object object) |
java.lang.Class<?>[] |
getActualTypeArguments() |
<A extends java.lang.annotation.Annotation> |
getAnnotation(java.lang.Class<A> annotationType)
Returns property's annotation for the given type or
null if it's not present. |
java.util.List<java.lang.annotation.Annotation> |
getAnnotations()
Returns the annotations that are present on this property or empty
List if there're no
annotations. |
java.lang.String |
getName() |
java.lang.Class<?> |
getType() |
boolean |
isReadable() |
boolean |
isWritable() |
void |
set(java.lang.Object object,
java.lang.Object value) |
void |
setActualTypeArguments(java.lang.Class<?>... args) |
void |
setDelegate(Property delegate) |
void |
setTargetType(java.lang.Class<?> targetType) |
private static final java.util.logging.Logger log
protected java.lang.Class<?> targetType
private final java.lang.String readMethod
private final java.lang.String writeMethod
private transient java.lang.reflect.Method read
private transient java.lang.reflect.Method write
private java.lang.reflect.Field field
protected java.lang.Class<?>[] parameters
private Property delegate
private boolean filler
public PropertySubstitute(java.lang.String name, java.lang.Class<?> type, java.lang.String readMethod, java.lang.String writeMethod, java.lang.Class<?>... params)
public PropertySubstitute(java.lang.String name, java.lang.Class<?> type, java.lang.Class<?>... params)
public java.lang.Class<?>[] getActualTypeArguments()
getActualTypeArguments
in class Property
public void setActualTypeArguments(java.lang.Class<?>... args)
public void set(java.lang.Object object, java.lang.Object value) throws java.lang.Exception
public java.util.List<java.lang.annotation.Annotation> getAnnotations()
Property
List
if there're no
annotations.getAnnotations
in class Property
List
if there're no
annotationspublic <A extends java.lang.annotation.Annotation> A getAnnotation(java.lang.Class<A> annotationType)
Property
null
if it's not present.getAnnotation
in class Property
A
- class of the annotationannotationType
- the type of the annotation to be returnednull
if it's not presentpublic void setTargetType(java.lang.Class<?> targetType)
private java.lang.reflect.Method discoverMethod(java.lang.Class<?> type, java.lang.String name, java.lang.Class<?>... params)
public boolean isReadable()
isReadable
in class Property
public boolean isWritable()
isWritable
in class Property
public void setDelegate(Property delegate)