Package org.hibernate.id.insert
Class UniqueKeySelectingDelegate
- java.lang.Object
-
- org.hibernate.id.insert.AbstractSelectingDelegate
-
- org.hibernate.id.insert.UniqueKeySelectingDelegate
-
- All Implemented Interfaces:
InsertGeneratedIdentifierDelegate
public class UniqueKeySelectingDelegate extends AbstractSelectingDelegate
Uses a unique key of the inserted entity to locate the newly inserted row.
-
-
Constructor Summary
Constructors Constructor Description UniqueKeySelectingDelegate(PostInsertIdentityPersister persister, Dialect dialect, String[] uniqueKeyPropertyNames)
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected voidbindParameters(Object entity, PreparedStatement ps, SharedSessionContractImplementor session)TableInsertBuildercreateTableInsertBuilder(BasicEntityIdentifierMapping identifierMapping, Expectation expectation, SessionFactoryImplementor factory)Create aTableInsertBuilderwith any specific identity handling already built in.protected StringgetSelectSQL()Get the SQL statement to be used to retrieve generated key values.IdentifierGeneratingInsertprepareIdentifierGeneratingInsert(SqlStringGenerationContext context)Deprecated.-
Methods inherited from class org.hibernate.id.insert.AbstractSelectingDelegate
extractGeneratedValue, performInsert, performInsert, prepareStatement
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.hibernate.id.insert.InsertGeneratedIdentifierDelegate
prepareIdentifierGeneratingInsert
-
-
-
-
Constructor Detail
-
UniqueKeySelectingDelegate
public UniqueKeySelectingDelegate(PostInsertIdentityPersister persister, Dialect dialect, String[] uniqueKeyPropertyNames)
-
-
Method Detail
-
getSelectSQL
protected String getSelectSQL()
Description copied from class:AbstractSelectingDelegateGet the SQL statement to be used to retrieve generated key values.- Specified by:
getSelectSQLin classAbstractSelectingDelegate- Returns:
- The SQL command string
-
prepareIdentifierGeneratingInsert
@Deprecated public IdentifierGeneratingInsert prepareIdentifierGeneratingInsert(SqlStringGenerationContext context)
Deprecated.Description copied from interface:InsertGeneratedIdentifierDelegateBuild an insert statement specific to the delegate's mode of handling generated key values.- Parameters:
context- A context to help generate SQL strings- Returns:
- An
IdentifierGeneratingInsert
-
createTableInsertBuilder
public TableInsertBuilder createTableInsertBuilder(BasicEntityIdentifierMapping identifierMapping, Expectation expectation, SessionFactoryImplementor factory)
Description copied from interface:InsertGeneratedIdentifierDelegateCreate aTableInsertBuilderwith any specific identity handling already built in.
-
bindParameters
protected void bindParameters(Object entity, PreparedStatement ps, SharedSessionContractImplementor session) throws SQLException
- Overrides:
bindParametersin classAbstractSelectingDelegate- Throws:
SQLException
-
-