Package org.apache.openjpa.enhance
Class ReflectingPersistenceCapable
- java.lang.Object
-
- org.apache.openjpa.enhance.ReflectingPersistenceCapable
-
- All Implemented Interfaces:
java.io.Serializable
,ManagedInstanceProvider
,PersistenceCapable
public class ReflectingPersistenceCapable extends java.lang.Object implements PersistenceCapable, ManagedInstanceProvider, java.io.Serializable
Implementation of thePersistenceCapable
interface that can handle the persistence-capable contract for instances that were not enhanced before class load time.- Since:
- 1.0.0
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from interface org.apache.openjpa.enhance.PersistenceCapable
CHECK_READ, CHECK_WRITE, DESERIALIZED, LOAD_REQUIRED, MEDIATE_READ, MEDIATE_WRITE, READ_OK, READ_WRITE_OK, SERIALIZABLE
-
-
Constructor Summary
Constructors Constructor Description ReflectingPersistenceCapable(java.lang.Object o, OpenJPAConfiguration conf)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Object
getManagedInstance()
void
pcCopyField(java.lang.Object fromObject, int i)
void
pcCopyFields(java.lang.Object fromObject, int[] fieldIndices)
void
pcCopyKeyFieldsFromObjectId(FieldConsumer consumer, java.lang.Object obj)
void
pcCopyKeyFieldsToObjectId(java.lang.Object oid)
void
pcCopyKeyFieldsToObjectId(FieldSupplier supplier, java.lang.Object obj)
void
pcDirty(java.lang.String fieldName)
java.lang.Object
pcFetchObjectId()
java.lang.Object
pcGetDetachedState()
int
pcGetEnhancementContractVersion()
java.lang.Object
pcGetGenericContext()
StateManager
pcGetStateManager()
java.lang.Object
pcGetVersion()
boolean
pcIsDeleted()
java.lang.Boolean
pcIsDetached()
boolean
pcIsDirty()
boolean
pcIsNew()
boolean
pcIsPersistent()
boolean
pcIsSerializationUserVisible()
boolean
pcIsTransactional()
PersistenceCapable
pcNewInstance(StateManager sm, boolean clear)
PersistenceCapable
pcNewInstance(StateManager sm, java.lang.Object oid, boolean clear)
java.lang.Object
pcNewObjectIdInstance()
java.lang.Object
pcNewObjectIdInstance(java.lang.Object oid)
void
pcProvideField(int i)
void
pcProvideFields(int[] fieldIndices)
void
pcReplaceField(int i)
void
pcReplaceFields(int[] fieldIndices)
void
pcReplaceStateManager(StateManager sm)
void
pcSetDetachedState(java.lang.Object state)
void
pcSetSerializationUserVisible(boolean userVisible)
-
-
-
Constructor Detail
-
ReflectingPersistenceCapable
public ReflectingPersistenceCapable(java.lang.Object o, OpenJPAConfiguration conf)
-
-
Method Detail
-
pcGetEnhancementContractVersion
public int pcGetEnhancementContractVersion()
- Specified by:
pcGetEnhancementContractVersion
in interfacePersistenceCapable
-
pcGetGenericContext
public java.lang.Object pcGetGenericContext()
- Specified by:
pcGetGenericContext
in interfacePersistenceCapable
-
pcGetStateManager
public StateManager pcGetStateManager()
- Specified by:
pcGetStateManager
in interfacePersistenceCapable
-
pcReplaceStateManager
public void pcReplaceStateManager(StateManager sm)
- Specified by:
pcReplaceStateManager
in interfacePersistenceCapable
-
pcProvideField
public void pcProvideField(int i)
- Specified by:
pcProvideField
in interfacePersistenceCapable
-
pcProvideFields
public void pcProvideFields(int[] fieldIndices)
- Specified by:
pcProvideFields
in interfacePersistenceCapable
-
pcReplaceField
public void pcReplaceField(int i)
- Specified by:
pcReplaceField
in interfacePersistenceCapable
-
pcReplaceFields
public void pcReplaceFields(int[] fieldIndices)
- Specified by:
pcReplaceFields
in interfacePersistenceCapable
-
pcCopyField
public void pcCopyField(java.lang.Object fromObject, int i)
-
pcCopyFields
public void pcCopyFields(java.lang.Object fromObject, int[] fieldIndices)
- Specified by:
pcCopyFields
in interfacePersistenceCapable
-
pcDirty
public void pcDirty(java.lang.String fieldName)
- Specified by:
pcDirty
in interfacePersistenceCapable
-
pcFetchObjectId
public java.lang.Object pcFetchObjectId()
- Specified by:
pcFetchObjectId
in interfacePersistenceCapable
-
pcGetVersion
public java.lang.Object pcGetVersion()
- Specified by:
pcGetVersion
in interfacePersistenceCapable
-
pcIsDirty
public boolean pcIsDirty()
- Specified by:
pcIsDirty
in interfacePersistenceCapable
-
pcIsTransactional
public boolean pcIsTransactional()
- Specified by:
pcIsTransactional
in interfacePersistenceCapable
-
pcIsPersistent
public boolean pcIsPersistent()
- Specified by:
pcIsPersistent
in interfacePersistenceCapable
-
pcIsNew
public boolean pcIsNew()
- Specified by:
pcIsNew
in interfacePersistenceCapable
-
pcIsDeleted
public boolean pcIsDeleted()
- Specified by:
pcIsDeleted
in interfacePersistenceCapable
-
pcIsDetached
public java.lang.Boolean pcIsDetached()
- Specified by:
pcIsDetached
in interfacePersistenceCapable
-
pcNewInstance
public PersistenceCapable pcNewInstance(StateManager sm, boolean clear)
- Specified by:
pcNewInstance
in interfacePersistenceCapable
-
pcNewInstance
public PersistenceCapable pcNewInstance(StateManager sm, java.lang.Object oid, boolean clear)
- Specified by:
pcNewInstance
in interfacePersistenceCapable
-
pcNewObjectIdInstance
public java.lang.Object pcNewObjectIdInstance()
- Specified by:
pcNewObjectIdInstance
in interfacePersistenceCapable
-
pcNewObjectIdInstance
public java.lang.Object pcNewObjectIdInstance(java.lang.Object oid)
- Specified by:
pcNewObjectIdInstance
in interfacePersistenceCapable
-
pcCopyKeyFieldsToObjectId
public void pcCopyKeyFieldsToObjectId(java.lang.Object oid)
- Specified by:
pcCopyKeyFieldsToObjectId
in interfacePersistenceCapable
-
pcCopyKeyFieldsToObjectId
public void pcCopyKeyFieldsToObjectId(FieldSupplier supplier, java.lang.Object obj)
- Specified by:
pcCopyKeyFieldsToObjectId
in interfacePersistenceCapable
-
pcCopyKeyFieldsFromObjectId
public void pcCopyKeyFieldsFromObjectId(FieldConsumer consumer, java.lang.Object obj)
- Specified by:
pcCopyKeyFieldsFromObjectId
in interfacePersistenceCapable
-
pcGetDetachedState
public java.lang.Object pcGetDetachedState()
- Specified by:
pcGetDetachedState
in interfacePersistenceCapable
-
pcSetDetachedState
public void pcSetDetachedState(java.lang.Object state)
- Specified by:
pcSetDetachedState
in interfacePersistenceCapable
-
pcSetSerializationUserVisible
public void pcSetSerializationUserVisible(boolean userVisible)
-
pcIsSerializationUserVisible
public boolean pcIsSerializationUserVisible()
-
getManagedInstance
public java.lang.Object getManagedInstance()
- Specified by:
getManagedInstance
in interfaceManagedInstanceProvider
-
-