org.apache.openjpa.kernel
Class DetachedStateAttachStrategy
java.lang.Object
org.apache.openjpa.kernel.TransferFieldManager
org.apache.openjpa.kernel.AttachStrategy
org.apache.openjpa.kernel.DetachedStateAttachStrategy
- All Implemented Interfaces:
- FieldConsumer, FieldManager, FieldSupplier
class DetachedStateAttachStrategy
- extends AttachStrategy
Handles attaching instances with detached state.
- Author:
- Marc Prud'hommeaux
Methods inherited from class org.apache.openjpa.kernel.TransferFieldManager |
clear, fetchBooleanField, fetchByteField, fetchCharField, fetchDoubleField, fetchFloatField, fetchIntField, fetchLongField, fetchObjectField, fetchShortField, fetchStringField, storeBooleanField, storeByteField, storeCharField, storeDoubleField, storeFloatField, storeIntField, storeLongField, storeObjectField, storeShortField, storeStringField |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DetachedStateAttachStrategy
DetachedStateAttachStrategy()
getDetachedObjectId
protected Object getDetachedObjectId(AttachManager manager,
Object toAttach)
- Description copied from class:
AttachStrategy
- Return the identity of the given detached instance.
- Specified by:
getDetachedObjectId
in class AttachStrategy
provideField
protected void provideField(Object toAttach,
StateManagerImpl sm,
int field)
- Description copied from class:
AttachStrategy
- Provide the given field into this field manager.
- Specified by:
provideField
in class AttachStrategy
attach
public Object attach(AttachManager manager,
Object toAttach,
ClassMetaData meta,
PersistenceCapable into,
OpenJPAStateManager owner,
ValueMetaData ownerMeta,
boolean explicit)
- Description copied from class:
AttachStrategy
- Attach.
- Specified by:
attach
in class AttachStrategy
- Parameters:
manager
- manager holding cache of attached instancestoAttach
- detached instancemeta
- metadata for the instance being attachedinto
- instance we're attaching intoowner
- state manager for into
ownerMeta
- field we traversed to find toAttach
explicit
- whether to make new instances explicitly persistent
Copyright © 2006-2012 Apache Software Foundation. All Rights Reserved.