@Override public Object resolve(Object value, SharedSessionContractImplementor session, Object owner, Boolean overridingEager) throws HibernateException { return resolveKey( getKeyOfOwner( owner, session ), session, owner, overridingEager ); }
@Override public Serializable disassemble(Object value, SharedSessionContractImplementor session, Object owner) throws HibernateException { //remember the uk value //This solution would allow us to eliminate the owner arg to disassemble(), but //what if the collection was null, and then later had elements added? seems unsafe //session.getPersistenceContext().getCollectionEntry( (PersistentCollection) value ).getKey(); final Serializable key = getKeyOfOwner(owner, session); if (key==null) { return null; } else { return getPersister(session) .getKeyType() .disassemble( key, session, owner ); } }
protected Serializable findCollectionOwnerKey(ResultSetProcessingContextImpl context) { Object owner = context.getOwnerProcessingState( (Fetch) collectionReference ).getEntityInstance(); return collectionReference.getCollectionPersister().getCollectionType().getKeyOfOwner( owner, context.getSession() ); }
protected Serializable getCollectionKey( CollectionPersister persister, Object owner, EntityEntry ownerEntry, SharedSessionContractImplementor session) { final CollectionType collectionType = persister.getCollectionType(); if ( ownerEntry != null ) { // this call only works when the owner is associated with the Session, which is not always the case return collectionType.getKeyOfOwner( owner, session ); } if ( collectionType.getLHSPropertyName() == null ) { // collection key is defined by the owning entity identifier return persister.getOwnerEntityPersister().getIdentifier( owner, session ); } else { return (Serializable) persister.getOwnerEntityPersister().getPropertyValue( owner, collectionType.getLHSPropertyName() ); } }
key = collectionPersister.getCollectionType().getKeyOfOwner( owner, session );
collectionType.getKeyOfOwner( parent, eventSource ), eventSource, parent,
ce.setCurrentKey( type.getKeyOfOwner( entity, session ) );
public Object resolve(Object value, SessionImplementor session, Object owner) throws HibernateException { return resolveKey( getKeyOfOwner( owner, session ), session, owner ); }
public Object resolve(Object value, SessionImplementor session, Object owner) throws HibernateException { return resolveKey( getKeyOfOwner( owner, session ), session, owner ); }
public Object resolve(Object value, SessionImplementor session, Object owner) throws HibernateException { return resolveKey( getKeyOfOwner( owner, session ), session, owner ); }
public Object resolve(Object value, SessionImplementor session, Object owner) throws HibernateException { return resolveKey( getKeyOfOwner( owner, session ), session, owner ); }
public Serializable disassemble(Object value, SessionImplementor session, Object owner) throws HibernateException { //remember the uk value //This solution would allow us to eliminate the owner arg to disassemble(), but //what if the collection was null, and then later had elements added? seems unsafe //session.getPersistenceContext().getCollectionEntry( (PersistentCollection) value ).getKey(); final Serializable key = getKeyOfOwner(owner, session); if (key==null) { return null; } else { return getPersister(session) .getKeyType() .disassemble( key, session, owner ); } }
public Serializable disassemble(Object value, SessionImplementor session, Object owner) throws HibernateException { //remember the uk value //This solution would allow us to eliminate the owner arg to disassemble(), but //what if the collection was null, and then later had elements added? seems unsafe //session.getPersistenceContext().getCollectionEntry( (PersistentCollection) value ).getKey(); final Serializable key = getKeyOfOwner(owner, session); if (key==null) { return null; } else { return getPersister(session) .getKeyType() .disassemble( key, session, owner ); } }
public Serializable disassemble(Object value, SessionImplementor session, Object owner) throws HibernateException { //remember the uk value //This solution would allow us to eliminate the owner arg to disassemble(), but //what if the collection was null, and then later had elements added? seems unsafe //session.getPersistenceContext().getCollectionEntry( (PersistentCollection) value ).getKey(); final Serializable key = getKeyOfOwner(owner, session); if (key==null) { return null; } else { return getPersister(session) .getKeyType() .disassemble( key, session, owner ); } }
public Serializable disassemble(Object value, SessionImplementor session, Object owner) throws HibernateException { //remember the uk value //This solution would allow us to eliminate the owner arg to disassemble(), but //what if the collection was null, and then later had elements added? seems unsafe //session.getPersistenceContext().getCollectionEntry( (PersistentCollection) value ).getKey(); final Serializable key = getKeyOfOwner(owner, session); if (key==null) { return null; } else { return getPersister(session) .getKeyType() .disassemble( key, session, owner ); } }
key = collectionPersister.getCollectionType().getKeyOfOwner( owner, session );
.getKeyOfOwner( owner, session );
key = collectionPersister.getCollectionType().getKeyOfOwner( owner, session );
key = collectionPersister.getCollectionType().getKeyOfOwner( owner, session );
key = collectionPersister.getCollectionType().getKeyOfOwner( owner, session );