@Override public <T> T get(Class<T> entityClass, Serializable id) throws HibernateException { return this.byId( entityClass ).load( id ); }
@Override public Object get(String entityName, Serializable id) throws HibernateException { return this.byId( entityName ).load( id ); }
@Override public <T> T load(Class<T> entityClass, Serializable id) throws HibernateException { return this.byId( entityClass ).getReference( id ); }
@Override public Object load(String entityName, Serializable id) throws HibernateException { return this.byId( entityName ).getReference( id ); }
@Override public <T> T get(Class<T> entityClass, Serializable id, LockOptions lockOptions) throws HibernateException { return this.byId( entityClass ).with( lockOptions ).load( id ); }
@Override public <T> T load(Class<T> entityClass, Serializable id, LockOptions lockOptions) throws HibernateException { return this.byId( entityClass ).with( lockOptions ).getReference( id ); }
@Override public Object load(String entityName, Serializable id, LockOptions lockOptions) throws HibernateException { return this.byId( entityName ).with( lockOptions ).getReference( id ); }
@Override public Object get(String entityName, Serializable id, LockOptions lockOptions) throws HibernateException { return this.byId( entityName ).with( lockOptions ).load( id ); }
@Override public <T> T getReference(Class<T> entityClass, Object primaryKey) { checkOpen(); try { return byId( entityClass ).getReference( (Serializable) primaryKey ); } catch ( MappingException | TypeMismatchException | ClassCastException e ) { throw exceptionConverter.convert( new IllegalArgumentException( e.getMessage(), e ) ); } catch ( RuntimeException e ) { throw exceptionConverter.convert( e ); } }
@Override public <T> T get(Class<T> entityClass, Serializable id, LockMode lockMode) throws HibernateException { return this.byId( entityClass ).with( new LockOptions( lockMode ) ).load( id ); }
@Override public Object get(String entityName, Serializable id, LockMode lockMode) throws HibernateException { return this.byId( entityName ).with( new LockOptions( lockMode ) ).load( id ); }
@Override public <T> T load(Class<T> entityClass, Serializable id, LockMode lockMode) throws HibernateException { return this.byId( entityClass ).with( new LockOptions( lockMode ) ).getReference( id ); }
@Override public Object load(String entityName, Serializable id, LockMode lockMode) throws HibernateException { return this.byId( entityName ).with( new LockOptions( lockMode ) ).getReference( id ); }
getLoadQueryInfluencers().getEffectiveEntityGraph().applyConfiguredGraph( properties ); final IdentifierLoadAccess<T> loadAccess = byId( entityClass ); loadAccess.with( determineAppropriateLocalCacheMode( properties ) );
@Override public Object load(String entityName, Object id) throws HibernateException { return this.byId( entityName ).getReference( id ); }
@Override public Object get(String entityName, Object id, LockOptions lockOptions) throws HibernateException { return this.byId( entityName ).with( lockOptions ).load( id ); }
@Override public <T> T getReference(Class<T> entityClass, Object primaryKey) { checkOpen(); try { return byId( entityClass ).getReference( (Serializable) primaryKey ); } catch ( MappingException | TypeMismatchException | ClassCastException e ) { throw exceptionConverter.convert( new IllegalArgumentException( e.getMessage(), e ) ); } catch ( RuntimeException e ) { throw exceptionConverter.convert( e ); } }
@Override public <T> T get(Class<T> entityClass, Object id, LockMode lockMode) throws HibernateException { return this.byId( entityClass ).with( new LockOptions( lockMode ) ).load( id ); }
@Override public Object load(String entityName, Object id, LockMode lockMode) throws HibernateException { return this.byId( entityName ).with( new LockOptions( lockMode ) ).getReference( id ); }
@Override public Object get(String entityName, Object id, LockMode lockMode) throws HibernateException { return this.byId( entityName ).with( new LockOptions( lockMode ) ).load( id ); }