|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectca.infoway.messagebuilder.j5goodies.BeanProperty
public class BeanProperty
A class to make bean reflection easier.
Method Summary | ||
---|---|---|
Object |
get()
Get the property value. |
|
|
getAnnotation(Class<T> annotationType)
|
|
Object |
getBean()
Get the bean. |
|
Class<?> |
getBeanType()
Get the type of the property's bean. |
|
PropertyDescriptor |
getDescriptor()
Get the property descriptor. |
|
String |
getName()
Get the property name. |
|
static Map<String,BeanProperty> |
getProperties(Object bean)
Get all properties of the bean. |
|
static BeanProperty |
getProperty(Object bean,
String propertyName)
Get a specific property. |
|
Class<?> |
getPropertyType()
Get the declared type of the property. |
|
Method |
getReadMethod()
Get the read method of the bean property. |
|
Method |
getWriteMethod()
Get the write method of the bean property. |
|
boolean |
isCollection()
Indicates whether or not the property type is a collection. |
|
boolean |
isReadable()
Indicate whether or not the bean is readable. |
|
boolean |
isWritable()
Indicate whether or not the bean is writable. |
|
void |
set(Object value)
Set the property value. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public Class<?> getBeanType()
Get the type of the property's bean.
public String getName()
Get the property name.
public Class<?> getPropertyType()
Get the declared type of the property.
public boolean isReadable()
Indicate whether or not the bean is readable.
public boolean isWritable()
Indicate whether or not the bean is writable.
public Method getReadMethod()
Get the read method of the bean property.
public Method getWriteMethod()
Get the write method of the bean property.
public void set(Object value)
Set the property value.
value
- - the new valuepublic Object get()
Get the property value.
public static Map<String,BeanProperty> getProperties(Object bean)
Get all properties of the bean.
bean
- - the bean to introspect.
public static BeanProperty getProperty(Object bean, String propertyName)
Get a specific property.
bean
- - the bean to be introspected.propertyName
- - the name of the property
public PropertyDescriptor getDescriptor()
Get the property descriptor.
public Object getBean()
Get the bean.
public boolean isCollection()
Indicates whether or not the property type is a collection.
public <T extends Annotation> T getAnnotation(Class<T> annotationType)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |