Package org.apache.cayenne.reflect
Class IdMapKeyAccessor
- java.lang.Object
-
- org.apache.cayenne.reflect.IdMapKeyAccessor
-
- All Implemented Interfaces:
Serializable
,Accessor
public class IdMapKeyAccessor extends Object implements Accessor
A stateless read-only accessor of the map key value that is based on the Persistent object id. For single-column ID's the accessor returns a single value (e.g. an Integer). For multi-column ID's it returns the ObjectId.- Since:
- 3.0
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static Accessor
SHARED_ACCESSOR
-
Constructor Summary
Constructors Constructor Description IdMapKeyAccessor()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getName()
Returns property name.Object
getValue(Object object)
Returns a property value of an object without disturbing the object fault status.void
setValue(Object object, Object newValue)
Sets a property value of an object without disturbing the object fault status.
-
-
-
Field Detail
-
SHARED_ACCESSOR
public static final Accessor SHARED_ACCESSOR
-
-
Method Detail
-
getValue
public Object getValue(Object object) throws PropertyException
Description copied from interface:Accessor
Returns a property value of an object without disturbing the object fault status.- Specified by:
getValue
in interfaceAccessor
- Throws:
PropertyException
-
setValue
public void setValue(Object object, Object newValue) throws PropertyException
Description copied from interface:Accessor
Sets a property value of an object without disturbing the object fault status. Old value of the property is specified as a hint.- Specified by:
setValue
in interfaceAccessor
- Throws:
PropertyException
-
-