public class BeanDescriptor
extends java.lang.Object
| Modifier and Type | Method | Description |
|---|---|---|
static int |
clearCache() |
Clear the ClassDescriptor cache.
|
java.lang.String[] |
getDistinctMethodNames() |
Gets the class methods' names that is unique.
|
java.lang.reflect.Method |
getGetter(java.lang.String name) |
Gets the getter for a property as a Method object.
|
java.lang.Class<?> |
getGetterType(java.lang.String name) |
Gets the type for a property getter.
|
static BeanDescriptor |
getInstance(java.lang.Class<?> clazz) |
Gets an instance of ClassDescriptor for the specified class.
|
java.lang.String[] |
getReadablePropertyNames() |
Gets an array of the readable properties for an object.
|
java.lang.String[] |
getReadablePropertyNamesWithoutNonSerializable() |
|
java.lang.reflect.Method |
getSetter(java.lang.String name) |
Gets the setter for a property as a Method object.
|
java.lang.Class<?> |
getSetterType(java.lang.String name) |
Gets the type for a property setter.
|
java.lang.String[] |
getWritablePropertyNames() |
Gets an array of the writable properties for an object.
|
boolean |
hasReadableProperty(java.lang.String propertyName) |
Check to see if a class has a readable property by name.
|
boolean |
hasWritableProperty(java.lang.String propertyName) |
Check to see if a class has a writable property by name.
|
static void |
setCacheEnabled(boolean cacheEnabling) |
You can manually turn off caching enabled by default.
|
public java.lang.reflect.Method getSetter(java.lang.String name)
throws java.lang.NoSuchMethodException
name - the name of the propertyjava.lang.NoSuchMethodException - when a setter method cannot be foundpublic java.lang.reflect.Method getGetter(java.lang.String name)
throws java.lang.NoSuchMethodException
name - the name of the propertyjava.lang.NoSuchMethodException - when a getter method cannot be foundpublic java.lang.Class<?> getSetterType(java.lang.String name)
throws java.lang.NoSuchMethodException
name - the name of the propertyjava.lang.NoSuchMethodException - when a getter method cannot be foundpublic java.lang.Class<?> getGetterType(java.lang.String name)
throws java.lang.NoSuchMethodException
name - the name of the propertyjava.lang.NoSuchMethodException - when a getter method cannot be foundpublic java.lang.String[] getReadablePropertyNames()
public java.lang.String[] getReadablePropertyNamesWithoutNonSerializable()
public java.lang.String[] getWritablePropertyNames()
public boolean hasWritableProperty(java.lang.String propertyName)
propertyName - the name of the property to checkpublic boolean hasReadableProperty(java.lang.String propertyName)
propertyName - the name of the property to checkpublic java.lang.String[] getDistinctMethodNames()
public static BeanDescriptor getInstance(java.lang.Class<?> clazz)
clazz - the class for which to lookup the method cachepublic static void setCacheEnabled(boolean cacheEnabling)
cacheEnabling - if true, turn caching on; otherwise, turn off cachingpublic static int clearCache()
Copyright © 2008–2018 The Aspectran Project. All rights reserved.