Deprecated
as a consequence of Session being deprecated. See corresponding docs for further information.
Supplier.
When the decorated instance is readily available, one
should prefer using SessionDelegatorBaseImpl.
Another difference with SessionDelegatorBaseImpl is that
this type only implements Session.
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | addEventListeners(SessionEventListener...
The listener(s) to add listeners)Implements org. |
| public Transaction | beginTransaction()
Implements org. Transaction object.
|
| public Session. | buildLockRequest(LockOptions
contains the lock level lockOptions)Implements org. |
| public IdentifierLoadAccess | byId(String
The entity name of the entity type to be retrieved entityName)Implements org. IdentifierLoadAccess instance to retrieve the specified entity type by
primary key.
|
| public <T> IdentifierLoadAccess | byId(Class<T>
The entity type to be retrieved entityClass)Implements org. IdentifierLoadAccess instance to retrieve the specified entity by
primary key.
|
| public <T> MultiIdentifierLoadAccess | byMultipleIds(Class<T>
The entity type to be retrieved entityClass)Implements org. MultiIdentifierLoadAccess instance to retrieve multiple entities at once
as specified by primary key values.
|
| public MultiIdentifierLoadAccess | byMultipleIds(String
The entity name of the entity type to be retrieved entityName)Implements org. MultiIdentifierLoadAccess instance to retrieve multiple entities at once
as specified by primary key values.
|
| public NaturalIdLoadAccess | byNaturalId(String
The entity name of the entity type to be retrieved entityName)Implements org. NaturalIdLoadAccess instance to retrieve the specified entity by
its natural id.
|
| public <T> NaturalIdLoadAccess | byNaturalId(Class<T>
The entity type to be retrieved entityClass)Implements org. NaturalIdLoadAccess instance to retrieve the specified entity by
its natural id.
|
| public SimpleNaturalIdLoadAccess | bySimpleNaturalId(String
The entity name of the entity type to be retrieved entityName)Implements org. SimpleNaturalIdLoadAccess instance to retrieve the specified entity by
its natural id.
|
| public <T> SimpleNaturalIdLoadAccess | bySimpleNaturalId(Class<T>
The entity type to be retrieved entityClass)Implements org. SimpleNaturalIdLoadAccess instance to retrieve the specified entity by
its simple (single attribute) natural id.
|
| public void | cancelQuery()
Implements org. |
| public void | |
| public void | close()
Implements org. |
| public boolean | contains(String
The entity name entityName, Object an instance of a persistent class object)Implements org. |
| public boolean | contains(Object
entity instance entity)Implements javax. |
| public Criteria | createCriteria(Class<T>
The class, which is an entity, or has entity subclasses/implementors persistentClass)Implements org.
Deprecated
Create Criteria instance for the given class (entity or subclasses/implementors).
|
| public Criteria | createCriteria(Class<T>
The class, which is an entity, or has entity subclasses/implementors persistentClass, String The alias to use alias)Implements org.
Deprecated
Create Criteria instance for the given class (entity or subclasses/implementors), using a specific
alias.
|
| public Criteria | createCriteria(String
The entity name entityName)Implements org.
Deprecated
Create Criteria instance for the given entity name.
|
| public Criteria | createCriteria(String
The entity name entityName, String The alias to use alias)Implements org.
Deprecated
Create Criteria instance for the given entity name, using a specific alias.
|
| public <T> RootGraph | createEntityGraph(Class<T>
class of entity graph rootType)Implements org. |
| public RootGraph | createEntityGraph(String
name of an entity graph graphName)Implements org. |
| public Query | createFilter(Object
a persistent collection collection, String a Hibernate query fragment. queryString)Implements org.
Deprecated
Create a Query instance for the given collection and filter string.
|
| public <T> Query | createNamedQuery(String
the name of a query defined in metadata name, Class<T> the type of the query result resultType)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
TypedQuery for executing a
Java Persistence query language named query.
|
| public Query | createNamedQuery(String
the name of a query defined in metadata name)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
Query for executing a named query
(in the Java Persistence query language or in native SQL).
|
| public StoredProcedureQuery | createNamedStoredProcedureQuery(String
name assigned to the stored procedure query
in metadata name)Implements javax. StoredProcedureQuery for executing a
stored procedure in the database.
|
| public NativeQuery | createNativeQuery(String
a native SQL query string sqlString)Implements org.
Deprecated
as a consequence of
Create an instance of NativeQuery being deprecated.
Query for executing
a native SQL statement, e.g., for update or delete.
|
| public NativeQuery | createNativeQuery(String
a native SQL query string sqlString, String the name of the result set mapping resultSetMapping)Implements org.
Deprecated
as a consequence of
Create an instance of NativeQuery being deprecated.
Query for executing
a native SQL query.
|
| public NativeQuery | createNativeQuery(String
a native SQL query string sqlString, Class<T> the class of the resulting instance(s) resultClass)Implements org.
Deprecated
as a consequence of
Create an instance of NativeQuery being deprecated.
Query for executing
a native SQL query.
|
| public <T> Query | createQuery(String
a Java Persistence query string queryString, Class<T> the type of the query result resultType)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
TypedQuery for executing a
Java Persistence query language statement.
|
| public <T> Query | createQuery(CriteriaQuery<T>
a criteria query object criteriaQuery)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
TypedQuery for executing a
criteria query.
|
| public Query | createQuery(CriteriaUpdate<T>
a criteria update query object updateQuery)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
Query for executing a criteria
update query.
|
| public Query | createQuery(CriteriaDelete<T>
a criteria delete query object deleteQuery)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
Query for executing a criteria
delete query.
|
| public Query | createQuery(String
a Java Persistence query string queryString)Implements org.
Deprecated
as a consequence of
Create an instance of Query being deprecated.
Query for executing a
Java Persistence query language statement.
|
| public NativeQuery | createSQLQuery(String
The SQL query queryString)Implements org.
Deprecated
as a consequence of
Create a NativeQuery being deprecated.
NativeQuery instance for the given SQL query string.
|
| public ProcedureCall | createStoredProcedureCall(String
The name of the procedure. procedureName)Implements org.
Deprecated
as a consequence of
Creates a call to a stored procedure.
ProcedureCall being deprecated.
|
| public ProcedureCall | createStoredProcedureCall(String
The name of the procedure. procedureName, Class<T>... The entity(s) to map the result on to. resultClasses)Implements org.
Deprecated
as a consequence of
Creates a call to a stored procedure with specific result set entity mappings.
ProcedureCall being deprecated.
|
| public ProcedureCall | createStoredProcedureCall(String
The name of the procedure. procedureName, String... The explicit result set mapping(s) to use for mapping the results resultSetMappings)Implements org.
Deprecated
as a consequence of
Creates a call to a stored procedure with specific result set entity mappings.
ProcedureCall being deprecated.
|
| public StoredProcedureQuery | createStoredProcedureQuery(String
name of the stored procedure in the
database procedureName)Implements javax. StoredProcedureQuery for executing a
stored procedure in the database.
|
| public StoredProcedureQuery | createStoredProcedureQuery(String
name of the stored procedure in the
database procedureName, Class<T>... classes to which the result sets
produced by the stored procedure are to
be mapped resultClasses)Implements javax. StoredProcedureQuery for executing a
stored procedure in the database.
|
| public StoredProcedureQuery | createStoredProcedureQuery(String
name of the stored procedure in the
database procedureName, String... the names of the result set mappings
to be used in mapping result sets
returned by the stored procedure resultSetMappings)Implements javax. StoredProcedureQuery for executing a
stored procedure in the database.
|
| public void | delete(Object
the instance to be removed object)Implements org. |
| public void | delete(String
The entity name for the instance to be removed. entityName, Object the instance to be removed object)Implements org. |
| public void | detach(Object
entity instance entity)Implements javax. |
| public void | disableFetchProfile(String
The name of the fetch profile to be disabled. name)Implements org. |
| public void | disableFilter(String
The name of the filter to be disabled. filterName)Implements org. |
| public Connection | disconnect()
Implements org. |
| public <T> T | doReturningWork(ReturningWork<T>
The work to be performed. work)Overrides default org. |
| public void | doWork(Work
The work to be performed. work)Overrides default org. |
| public void | enableFetchProfile(String
The name of the fetch profile to be enabled. name)Implements org. |
| public Filter | enableFilter(String
The name of the filter to be enabled. filterName)Implements org. |
| public void | evict(Object
The entity to evict object)Implements org. |
| public <T> T | find(Class<T>
entity class entityClass, Object primary key primaryKey)Implements javax. |
| public <T> T | |
| public <T> T | find(Class<T>
entity class entityClass, Object primary key primaryKey, LockModeType lock mode lockMode)Implements javax. |
| public <T> T | find(Class<T>
entity class entityClass, Object primary key primaryKey, LockModeType lock mode lockMode, Map<String, Object> standard and vendor-specific properties
and hints properties)Implements javax. |
| public void | |
| public <T> T | get(Class<T>
The entity type entityType, Serializable an identifier id)Implements org. |
| public <T> T | get(Class<T>
The entity type entityType, Serializable an identifier id, LockMode the lock mode lockMode)Implements org. |
| public <T> T | get(Class<T>
The entity type entityType, Serializable an identifier id, LockOptions the lock mode lockOptions)Implements org. |
| public Object | get(String
the entity name entityName, Serializable an identifier id)Implements org. |
| public Object | get(String
the entity name entityName, Serializable an identifier id, LockMode the lock mode lockMode)Implements org. |
| public Object | get(String
the entity name entityName, Serializable an identifier id, LockOptions contains the lock mode lockOptions)Implements org. |
| public CacheMode | |
| public CriteriaBuilder | getCriteriaBuilder()
Implements javax. CriteriaBuilder for the creation of
CriteriaQuery objects.
|
| public LockMode | getCurrentLockMode(Object
a persistent instance object)Implements org. |
| public Object | getDelegate()
Implements javax. EntityManager,
if available.
|
| public Filter | getEnabledFilter(String
The name of the filter to be retrieved. filterName)Implements org. |
| public RootGraph | getEntityGraph(String
name of an existing entity graph graphName)Implements org. |
| public <T> List | getEntityGraphs(Class<T>
entity class entityClass)Overrides default org. |
| public EntityManagerFactory | getEntityManagerFactory()
Implements javax. |
| public String | getEntityName(Object
a persistent entity object)Implements org. |
| public FlushModeType | getFlushMode()
Implements org. |
| public FlushMode | getHibernateFlushMode()
Implements org. |
| public Serializable | getIdentifier(Object
a persistent instance object)Implements org. |
| public Integer | getJdbcBatchSize()
Implements org. |
| public LobHelper | getLobHelper()
Implements org. |
| public LockModeType | getLockMode(Object
entity instance entity)Implements javax. |
| public Metamodel | getMetamodel()
Implements javax. Metamodel interface for access to the
metamodel of the persistence unit.
|
| public NativeQuery | getNamedNativeQuery(String
The name of the pre-defined query name)Implements org.
Deprecated
as a consequence of
Get a NativeQuery instance for a named native SQL query
NativeQuery being deprecated.
|
| public ProcedureCall | getNamedProcedureCall(String
The name given to the template name)Implements org.
Deprecated
as a consequence of
Gets a ProcedureCall based on a named template
ProcedureCall being deprecated.
|
| public Query | getNamedQuery(String
the name of a pre-defined, named query queryName)Implements org.
Deprecated
as a consequence of
Create a Query being deprecated.
Query instance for the named query.
|
| public Query | getNamedSQLQuery(String
The name of the pre-defined query name)Overrides default org.
Deprecated
Get a NativeQuery instance for a named native SQL query
|
| public Map | getProperties()
Implements javax. |
| public <T> T | getReference(T
a detached persistent instance object)Overrides default org. |
| public <T> T | getReference(Class<T>
entity class entityClass, Object primary key primaryKey)Implements javax. |
| public Session | getSession()
Implements org.
Deprecated
as a consequence of
Retrieve a reference to the Hibernate Session being deprecated.
org. used by this javax..
|
| public SessionFactory | getSessionFactory()
Implements org.
Deprecated
as a consequence of
Get the session factory which created this session.
SessionFactory being deprecated.
|
| public SessionStatistics | |
| public String | getTenantIdentifier()
Implements org. |
| public Transaction | getTransaction()
Implements org. Transaction instance associated with this session.
|
| public TypeHelper | getTypeHelper()
Implements org. TypeHelper associated with this session's SessionFactory.
|
| public boolean | isConnected()
Implements org. |
| public boolean | isDefaultReadOnly()
Implements org. |
| public boolean | isDirty()
Implements org. |
| public boolean | isFetchProfileEnabled(String
The name of the profile to be checked. name)Implements org. |
| public boolean | isJoinedToTransaction()
Implements javax. |
| public boolean | isOpen()
Implements org. |
| public boolean | isReadOnly(Object
an entity or HibernateProxy entityOrProxy)Implements org. |
| public void | joinTransaction()
Implements javax. |
| public <T> T | load(Class<T>
a persistent class theClass, Serializable a valid identifier of an existing persistent instance of the class id, LockMode the lock level lockMode)Implements org. |
| public <T> T | load(Class<T>
a persistent class theClass, Serializable a valid identifier of an existing persistent instance of the class id, LockOptions contains the lock level lockOptions)Implements org. |
| public Object | load(String
a persistent class entityName, Serializable a valid identifier of an existing persistent instance of the class id, LockMode the lock level lockMode)Implements org. |
| public Object | load(String
a persistent class entityName, Serializable a valid identifier of an existing persistent instance of the class id, LockOptions contains the lock level lockOptions)Implements org. |
| public <T> T | load(Class<T>
a persistent class theClass, Serializable a valid identifier of an existing persistent instance of the class id)Implements org. |
| public Object | load(String
a persistent class entityName, Serializable a valid identifier of an existing persistent instance of the class id)Implements org. |
| public void | load(Object
an "empty" instance of the persistent class object, Serializable a valid identifier of an existing persistent instance of the class id)Implements org. |
| public void | lock(Object
a persistent or transient instance object, LockMode the lock level lockMode)Implements org. |
| public void | lock(String
The name of the entity entityName, Object a persistent or transient instance object, LockMode the lock level lockMode)Implements org. |
| public void | lock(Object
entity instance entity, LockModeType lock mode lockMode)Implements javax. |
| public void | lock(Object
entity instance entity, LockModeType lock mode lockMode, Map<String, Object> standard and vendor-specific properties
and hints properties)Implements javax. |
| public Object | merge(Object
a detached instance with state to be copied object)Implements org. |
| public Object | merge(String
The entity name entityName, Object a detached instance with state to be copied object)Implements org. |
| public void | persist(Object
a transient instance to be made persistent object)Implements org. |
| public void | persist(String
The entity name entityName, Object a transient instance to be made persistent object)Implements org. |
| public void | reconnect(Connection
a JDBC connection connection)Implements org. |
| public void | refresh(Object
a persistent or detached instance object)Implements org. |
| public void | refresh(String
a persistent class entityName, Object a persistent or detached instance object)Implements org. |
| public void | refresh(Object
a persistent or detached instance object, LockMode the lock mode to use lockMode)Implements org. |
| public void | refresh(Object
a persistent or detached instance object, LockOptions contains the lock mode to use lockOptions)Implements org. |
| public void | refresh(String
a persistent class entityName, Object a persistent or detached instance object, LockOptions contains the lock mode to use lockOptions)Implements org. |
| public void | refresh(Object
entity instance entity, Map<String, Object> standard and vendor-specific properties
and hints properties)Implements javax. |
| public void | refresh(Object
entity instance entity, LockModeType lock mode lockMode)Implements javax. |
| public void | refresh(Object
entity instance entity, LockModeType lock mode lockMode, Map<String, Object> standard and vendor-specific properties
and hints properties)Implements javax. |
| public void | remove(Object
entity instance entity)Implements javax. |
| public void | replicate(Object
a detached instance of a persistent class object, ReplicationMode The replication mode to use replicationMode)Implements org. |
| public void | replicate(String
The entity name entityName, Object a detached instance of a persistent class object, ReplicationMode The replication mode to use replicationMode)Implements org. |
| public Serializable | save(Object
a transient instance of a persistent class object)Implements org. |
| public Serializable | save(String
The entity name entityName, Object a transient instance of a persistent class object)Implements org. |
| public void | saveOrUpdate(Object
a transient or detached instance containing new or updated state object)Implements org. save(Object) or update(Object) the given
instance, depending upon resolution of the unsaved-value checks (see the
manual for discussion of unsaved-value checking).
|
| public void | saveOrUpdate(String
The entity name entityName, Object a transient or detached instance containing new or updated state object)Implements org. save(String, Object) or update(String, Object)
the given instance, depending upon resolution of the unsaved-value checks
(see the manual for discussion of unsaved-value checking).
|
| public SharedSessionBuilder | sessionWithOptions()
Implements org. Session builder with the ability to grab certain information from this session.
|
| public void | setCacheMode(CacheMode
The new cache mode. cacheMode)Implements org. |
| public void | setDefaultReadOnly(boolean
true, the default for loaded entities/proxies is read-only;
false, the default for loaded entities/proxies is modifiable readOnly)Implements org. |
| public void | setFlushMode(FlushMode
the new flush mode flushMode)Implements org.
Deprecated
Set the flush mode for this session.
|
| public void | setFlushMode(FlushModeType
flush mode flushMode)Implements javax. |
| public void | setHibernateFlushMode(FlushMode
the new flush mode flushMode)Implements org. |
| public void | setJdbcBatchSize(Integer
Session-level JDBC batch size jdbcBatchSize)Implements org. |
| public void | setProperty(String
name of property or hint propertyName, Object value for property or hint value)Implements javax. |
| public void | setReadOnly(Object
an entity or HibernateProxy entityOrProxy, boolean true if the entity or proxy should be made read-only; false if the entity or
proxy should be made modifiableImplements org. |
| public <T> T | unwrap(Class<T>
the class of the object to be returned. This is
normally either the underlying cls)EntityManager implementation
class or an interface that it implements.Implements javax. |
| public void | update(Object
a detached instance containing updated state object)Implements org. |
| public void | update(String
The entity name entityName, Object a detached instance containing updated state object)Implements org. |