public abstract class UnitOfWorkValueHolder extends DatabaseValueHolder implements WrappingValueHolder
shouldToStringInstantiate
Modifier and Type | Method and Description |
---|---|
abstract java.lang.Object |
buildCloneFor(java.lang.Object originalAttributeValue)
Clone the original attribute value.
|
DatabaseMapping |
getMapping() |
ValueHolderInterface |
getWrappedValueHolder()
Returns the valueholder that is wrapped by this ValueHolder
|
java.rmi.server.ObjID |
getWrappedValueHolderRemoteID()
returns wrapped ValueHolder ObjID if available
|
java.lang.Object |
instantiateForUnitOfWorkValueHolder(UnitOfWorkValueHolder unitOfWorkValueHolder)
Triggers UnitOfWork valueholders directly without triggering the wrapped
valueholder (this).
|
boolean |
isEasilyInstantiated()
INTERNAL:
Answers if this valueholder is easy to instantiate.
|
boolean |
isPessimisticLockingValueHolder()
INTERNAL:
Answers if this valueholder is a pessimistic locking one.
|
boolean |
isSerializedRemoteUnitOfWorkValueHolder()
Used to determine if this is a remote uow value holder that was serialized to the server.
|
void |
releaseWrappedValueHolder(AbstractSession targetSession)
Releases a wrapped valueholder privately owned by a particular unit of work.
|
void |
setBackupValueHolder(ValueHolderInterface backupValueHolder) |
boolean |
shouldAllowInstantiationDeferral()
INTERNAL:
Return if add/remove should trigger instantiation or avoid.
|
clone, getRow, getSession, getValue, getValue, isCoordinatedWithProperty, isInstantiated, isNewlyWeavedValueHolder, postInstantiate, privilegedSetValue, setInstantiated, setIsCoordinatedWithProperty, setIsNewlyWeavedValueHolder, setRow, setSession, setUninstantiated, setValue, toString
public abstract java.lang.Object buildCloneFor(java.lang.Object originalAttributeValue)
public DatabaseMapping getMapping()
public boolean isEasilyInstantiated()
isEasilyInstantiated
in class DatabaseValueHolder
public boolean isPessimisticLockingValueHolder()
isPessimisticLockingValueHolder
in class DatabaseValueHolder
public ValueHolderInterface getWrappedValueHolder()
WrappingValueHolder
getWrappedValueHolder
in interface WrappingValueHolder
getWrappedValueHolder
in class DatabaseValueHolder
public java.rmi.server.ObjID getWrappedValueHolderRemoteID()
public boolean isSerializedRemoteUnitOfWorkValueHolder()
isSerializedRemoteUnitOfWorkValueHolder
in class DatabaseValueHolder
public java.lang.Object instantiateForUnitOfWorkValueHolder(UnitOfWorkValueHolder unitOfWorkValueHolder)
When in transaction and/or for pessimistic locking the UnitOfWorkValueHolder needs to be triggered directly without triggering the wrapped valueholder. However only the wrapped valueholder knows how to trigger the indirection, i.e. it may be a batchValueHolder, and it stores all the info like the row and the query.
instantiateForUnitOfWorkValueHolder
in class DatabaseValueHolder
public void releaseWrappedValueHolder(AbstractSession targetSession)
When unit of work clones are built directly from rows no object in the shared cache points to this valueholder, so it can store the unit of work as its session. However once that UnitOfWork commits and the valueholder is merged into the shared cache, the session needs to be reset to the root session, ie. the server session.
releaseWrappedValueHolder
in class DatabaseValueHolder
public void setBackupValueHolder(ValueHolderInterface backupValueHolder)
public boolean shouldAllowInstantiationDeferral()
shouldAllowInstantiationDeferral
in interface WeavedAttributeValueHolderInterface
shouldAllowInstantiationDeferral
in class DatabaseValueHolder
EclipseLink 2.6.3, "build v20160428-59c81c5" API Reference