org.pfsw.reflect
Interface AttributeReadAccess

All Known Subinterfaces:
AttributeReadWriteAccess
All Known Implementing Classes:
ObjectAccessWrapper, ObjectOrMapAccessWrapper

public interface AttributeReadAccess

Specifies the methods an object must implement to provide generic read access to its attributes.
Such attributes can be instance variables of an object or values stored in properties or maps.


Method Summary
 java.lang.String[] getAttributeNames()
          Returns the names of all attributes that can be accessed by the method getAttributeValue().
 java.lang.Object getAttributeValue(java.lang.String name)
          Returns the current value of the attribute with the given name.
 

Method Detail

getAttributeValue

java.lang.Object getAttributeValue(java.lang.String name)
                                   throws java.lang.NoSuchFieldException
Returns the current value of the attribute with the given name.

Parameters:
name - The attribute's name ( case sensitive )
Throws:
java.lang.NoSuchFieldException - If there is no attribute with the given name

getAttributeNames

java.lang.String[] getAttributeNames()
Returns the names of all attributes that can be accessed by the method getAttributeValue().