public class BeansUtil
extends java.lang.Object
Constructor and Description |
---|
BeansUtil() |
Modifier and Type | Method and Description |
---|---|
static AccessLevelBeanInfo |
asAccessLevelBeanInfo(java.beans.BeanInfo beanInfo,
java.lang.Class beanClass)
Returns an AccessLevelBeanInfo for the BeanInfo class, implementing the logic
of how to handle implicit properties.
|
static java.beans.PropertyEditor |
findEditor(java.lang.Class propertyClass) |
static java.beans.BeanInfo |
getBeanInfo(java.lang.Class c) |
static java.beans.PropertyEditor |
getEditor(java.beans.PropertyDescriptor pd)
One-stop place to get the editor for the given propertyDescriptor.
|
static java.beans.PropertyDescriptor[] |
getPropertyDescriptors(java.lang.Class c)
Use reflection to get a list of all the property names for the class.
|
static java.lang.String[] |
getPropertyNames(java.lang.Class c)
Use reflection to get a list of all the property names for the class.
|
static java.lang.String[] |
getPropertyNames(java.beans.PropertyDescriptor[] propertyList) |
static void |
registerEditor(java.lang.Class beanClass,
java.lang.Class editorClass)
see BeanBindingDemo2.java
|
public static void registerEditor(java.lang.Class beanClass, java.lang.Class editorClass)
beanClass
- the bean class, e.g. Datum.classeditorClass
- the editor class, e.g. DatumEditor.classpublic static java.beans.PropertyEditor findEditor(java.lang.Class propertyClass)
public static java.beans.PropertyEditor getEditor(java.beans.PropertyDescriptor pd)
pd
- the property descriptorpublic static java.beans.PropertyDescriptor[] getPropertyDescriptors(java.lang.Class c)
public static java.beans.BeanInfo getBeanInfo(java.lang.Class c) throws java.beans.IntrospectionException
java.beans.IntrospectionException
public static java.lang.String[] getPropertyNames(java.beans.PropertyDescriptor[] propertyList)
public static java.lang.String[] getPropertyNames(java.lang.Class c)
public static AccessLevelBeanInfo asAccessLevelBeanInfo(java.beans.BeanInfo beanInfo, java.lang.Class beanClass)