java.lang.Object java.beans.FeatureDescriptor java.beans.PropertyDescriptor java.beans.IndexedPropertyDescriptor
An IndexedPropertyDescriptor describes a property that acts like an array and has an indexed read and/or indexed write method to access specific elements of the array.
An indexed property may also provide simple non-indexed read and write methods. If these are present, they read and write arrays of the type returned by the indexed read method.
Constructor Summary | |
---|---|
IndexedPropertyDescriptor
(
String
propertyName,
Class
beanClass) This constructor constructs an IndexedPropertyDescriptor for a property that follows the standard Java conventions by having getFoo and setFoo accessor methods, for both indexed access and array access. |
|
IndexedPropertyDescriptor
(
String
propertyName,
Class
beanClass,
String
readMethodName,
This constructor takes the name of a simple property, and method names for reading and writing the property, both indexed and non-indexed. |
|
IndexedPropertyDescriptor
(
String
propertyName,
Method
readMethod,
This constructor takes the name of a simple property, and Method objects for reading and writing the property. |
Method Summary | |
---|---|
boolean |
equals
(
Object
obj) Compares this PropertyDescriptor against the specified object. |
Class |
getIndexedPropertyType
() Gets the Class object of the indexed properties' type. |
Method |
getIndexedReadMethod
() Gets the method that should be used to read an indexed property value. |
Method |
getIndexedWriteMethod
() Gets the method that should be used to write an indexed property value. |
int |
hashCode
()
Returns a hash code value for the object. |
|
|
void |
setIndexedReadMethod
Sets the method that should be used to read |
void |
setIndexedWriteMethod
(
Method
Sets the method that should be used to write an indexed property value. |
Methods inherited from class java.beans. PropertyDescriptor |
---|
createPropertyEditor , getPropertyEditorClass , getPropertyType , getReadMethod , getWriteMethod , isBound , isConstrained , setBound , setConstrained , setPropertyEditorClass , setReadMethod , setWriteMethod |
Methods inherited from class java.beans. FeatureDescriptor |
---|
attributeNames , getDisplayName , getName , getShortDescription , getValue , isExpert , isHidden , isPreferred , setDisplayName , setExpert , setHidden , setName , setPreferred , setShortDescription , setValue |
Methods inherited from class java.lang. Object |
---|
clone
,
finalize
,
getClass
,
|
Constructor Detail |
---|
public IndexedPropertyDescriptor(String propertyName, Class beanClass) throws IntrospectionException
Thus if the argument name is "fred", it will assume that there is an indexed reader method "getFred", a non-indexed (array) reader method also called "getFred", an indexed writer method "setFred", and finally a non-indexed writer method "setFred".
public IndexedPropertyDescriptor(String propertyName, Class beanClass, String readMethodName,getterName,String writeMethodName,setterName,String indexedReadMethodName,indexedGetterName,String indexedWriteMethodName)indexedSetterName)throws IntrospectionException
public IndexedPropertyDescriptor(String propertyName, Method readMethod,getter,Method writeMethod,setter,Method indexedReadMethod,indexedGetter,Method indexedWriteMethod)indexedSetter)throws IntrospectionException
Method Detail |
---|
public Method getIndexedReadMethod()
public void setIndexedReadMethod(Method readMethod)getter)throws IntrospectionException
public Method getIndexedWriteMethod()
public void setIndexedWriteMethod(Method writeMethod)setter)throws IntrospectionException
public Class getIndexedPropertyType()
public boolean equals(Object obj)
public int hashCode ()