public abstract class AttributeAccessor extends Object implements CoreAttributeAccessor, Cloneable, Serializable
Purpose: This provides an abstract class for setting and retrieving the attribute value for the mapping from an object. It can be used in advanced situations if the attribute requires advanced conversion of the mapping value, or a real attribute does not exist.
| Modifier and Type | Field and Description |
|---|---|
protected String |
attributeName
Stores the name of the attribute
|
protected boolean |
isReadOnly |
protected boolean |
isWriteOnly |
| Constructor and Description |
|---|
AttributeAccessor() |
| Modifier and Type | Method and Description |
|---|---|
Object |
clone()
INTERNAL:
Clones itself.
|
Class |
getAttributeClass()
Return the class type of the attribute.
|
String |
getAttributeName()
INTERNAL:
Return the attribute name.
|
abstract Object |
getAttributeValueFromObject(Object object)
Return the attribute value from the object.
|
void |
initializeAttributes(Class descriptorClass)
Allow any initialization to be performed with the descriptor class.
|
boolean |
isInitialized()
Returns true if this attribute accessor has been initialized and now stores a reference to the
class's attribute.
|
boolean |
isInstanceVariableAttributeAccessor() |
boolean |
isMapValueAttributeAccessor() |
boolean |
isMethodAttributeAccessor() |
boolean |
isReadOnly()
INTERNAL
|
boolean |
isValuesAccessor() |
boolean |
isVirtualAttributeAccessor() |
boolean |
isWriteOnly()
INTERNAL:
|
void |
setAttributeName(String attributeName)
INTERNAL:
Set the attribute name.
|
abstract void |
setAttributeValueInObject(Object object,
Object value)
Set the attribute value into the object.
|
void |
setIsReadOnly(boolean aBoolean)
INTERNAL
|
void |
setIsWriteOnly(boolean aBoolean)
INTERNAL:
|
protected String attributeName
protected boolean isWriteOnly
protected boolean isReadOnly
public String getAttributeName()
getAttributeName in interface CoreAttributeAccessorpublic void setAttributeName(String attributeName)
public Class getAttributeClass()
getAttributeClass in interface CoreAttributeAccessorpublic void initializeAttributes(Class descriptorClass) throws DescriptorException
initializeAttributes in interface CoreAttributeAccessorDescriptorExceptionpublic boolean isInitialized()
public boolean isInstanceVariableAttributeAccessor()
isInstanceVariableAttributeAccessor in interface CoreAttributeAccessorpublic boolean isMapValueAttributeAccessor()
public boolean isMethodAttributeAccessor()
isMethodAttributeAccessor in interface CoreAttributeAccessorpublic boolean isValuesAccessor()
public boolean isVirtualAttributeAccessor()
public boolean isWriteOnly()
isWriteOnly in interface CoreAttributeAccessorpublic void setIsWriteOnly(boolean aBoolean)
setIsWriteOnly in interface CoreAttributeAccessoraBoolean - public boolean isReadOnly()
public void setIsReadOnly(boolean aBoolean)
setIsReadOnly in interface CoreAttributeAccessoraBoolean - public abstract Object getAttributeValueFromObject(Object object) throws DescriptorException
getAttributeValueFromObject in interface CoreAttributeAccessorDescriptorExceptionpublic abstract void setAttributeValueInObject(Object object, Object value) throws DescriptorException
setAttributeValueInObject in interface CoreAttributeAccessorDescriptorExceptionCopyright © 2007–2021 Eclipse.org - EclipseLink Project. All rights reserved.