throws LockingException
{
ContextEntry entry;
LockManager lockManager;
Swizzling swizzlingStrategy;
IndirectionHandler handler = null;
OTMKit kit = _tx.getKit();
// Are we building object's relations for the userObject in the transaction?
// Otherwise we just get data from the "userObject" and put it into
// the previously loaded/created object in the transaction
boolean buildingObject = false;
boolean lazySwizzle = false;
if (lock == LockType.NO_LOCK)
{
return null;
}
entry = (ContextEntry) _objects.get(oid);
if (userObject == null)
{
// invalidating object...
_original.remove(oid);
_checkpointed.remove(oid);
if (entry != null)
{
entry.userObject = null;
entry.cacheObject = null;
}
return entry;
}
lockManager = LockManager.getInstance();
swizzlingStrategy = kit.getSwizzlingStrategy();
handler = ProxyHelper.getIndirectionHandler(userObject);
if ((handler != null) && handler.alreadyMaterialized())
{
userObject = handler.getRealSubject();
handler = null;
}
if ((entry == null) || (entry.userObject == null))
{