|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SharedSessionContract
Contract methods shared between Session
and StatelessSession
Method Summary | |
---|---|
Transaction |
beginTransaction()
Begin a unit of work and return the associated Transaction object. |
Criteria |
createCriteria(Class persistentClass)
Create Criteria instance for the given class (entity or subclasses/implementors) |
Criteria |
createCriteria(Class persistentClass,
String alias)
Create Criteria instance for the given class (entity or subclasses/implementors), using a specific
alias. |
Criteria |
createCriteria(String entityName)
Create Criteria instance for the given entity name. |
Criteria |
createCriteria(String entityName,
String alias)
Create Criteria instance for the given entity name, using a specific alias. |
Query |
createQuery(String queryString)
Create a Query instance for the given HQL query string. |
SQLQuery |
createSQLQuery(String queryString)
Create a SQLQuery instance for the given SQL query string. |
Query |
getNamedQuery(String queryName)
Create a Query instance for the named query string defined in the metadata. |
String |
getTenantIdentifier()
Obtain the tenant identifier associated with this session. |
Transaction |
getTransaction()
Get the Transaction instance associated with this session. |
Method Detail |
---|
String getTenantIdentifier()
null
Transaction beginTransaction()
Transaction
object. If a new underlying transaction is
required, begin the transaction. Otherwise continue the new work in the context of the existing underlying
transaction.
getTransaction()
Transaction getTransaction()
Transaction
instance associated with this session. The concrete type of the returned
Transaction
object is determined by the hibernate.transaction_factory
property.
Query getNamedQuery(String queryName)
Query
instance for the named query string defined in the metadata.
queryName
- the name of a query defined externally
Query createQuery(String queryString)
Query
instance for the given HQL query string.
queryString
- The HQL query
SQLQuery createSQLQuery(String queryString)
SQLQuery
instance for the given SQL query string.
queryString
- The SQL query
Criteria createCriteria(Class persistentClass)
Criteria
instance for the given class (entity or subclasses/implementors)
persistentClass
- The class, which is an entity, or has entity subclasses/implementors
Criteria createCriteria(Class persistentClass, String alias)
Criteria
instance for the given class (entity or subclasses/implementors), using a specific
alias.
persistentClass
- The class, which is an entity, or has entity subclasses/implementorsalias
- The alias to use
Criteria createCriteria(String entityName)
Criteria
instance for the given entity name.
entityName
- The entity name
Criteria createCriteria(String entityName, String alias)
Criteria
instance for the given entity name, using a specific alias.
entityName
- The entity namealias
- The alias to use
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |