public class FieldAccessPoint extends java.lang.Object implements AccessPoint
Constructor and Description |
---|
FieldAccessPoint(java.lang.reflect.Field inspectableField,
java.lang.Object accessed)
constructs an access point object from the given field and object.
|
FieldAccessPoint(java.lang.String name,
java.lang.reflect.Field inspectableField,
java.lang.Object inspected)
constructs an access point object from the given field and object.
|
FieldAccessPoint(java.lang.String fieldName,
java.lang.Object accessed)
constructs an access point object for the specified field name and the given
declaring object.
|
FieldAccessPoint(java.lang.String name,
java.lang.String fieldName,
java.lang.Object accessed)
constructs an access point object for the specified field name and the given
declaring object.
|
Modifier and Type | Method and Description |
---|---|
java.lang.String |
getFieldName() |
java.lang.String |
getName()
returns the name of this AccessPoint.
|
java.lang.Object |
getValue()
returns the current value of the attribute referenced by this access
point.
|
public FieldAccessPoint(java.lang.String fieldName, java.lang.Object accessed)
fieldName
must denote a
field declared in the class of declaringObject
or
inherited from one of its superclasses.fieldName
- the name of the field to be inspectedaccessed
- the object whose field values are to be inspectedpublic FieldAccessPoint(java.lang.reflect.Field inspectableField, java.lang.Object accessed)
inspectableField
must reference a field declared
in the class of declaringObject
or inherited from one of its
superclasses.inspectableField
- the field to be inspectedaccessed
- the accessed objectpublic FieldAccessPoint(java.lang.String name, java.lang.String fieldName, java.lang.Object accessed) throws ReflectException
fieldName
must denote a
field declared in the class of declaringObject
or
inherited from one of its superclasses. The name of the access point may differ
from the field name.name
- the name for this access pointfieldName
- the name of the field to be inspectedaccessed
- the object whose field values are to be inspectedReflectException
public FieldAccessPoint(java.lang.String name, java.lang.reflect.Field inspectableField, java.lang.Object inspected)
inspectableField
must reference a field declared in the
class of declaringObject
or inherited from one of its
superclasses. The name of the access point may differ from the field's name.name
- the name for this access pointinspectableField
- the field to be inspectedinspected
- the inspected objectpublic java.lang.Object getValue() throws ReflectException
AccessPoint
getValue
in interface AccessPoint
ReflectException
public java.lang.String getName()
AccessPoint
getName
in interface AccessPoint
public java.lang.String getFieldName()