org.hibernate.id

Class IdentityGenerator.GetGeneratedKeysDelegate

Enclosing Class:
IdentityGenerator
Implemented Interfaces:
InsertGeneratedIdentifierDelegate

public static class IdentityGenerator.GetGeneratedKeysDelegate
extends AbstractReturningDelegate
implements InsertGeneratedIdentifierDelegate

Delegate for dealing with IDENTITY columns using JDBC3 getGeneratedKeys

Constructor Summary

GetGeneratedKeysDelegate(PostInsertIdentityPersister persister, Dialect dialect)

Method Summary

Serializable
executeAndExtract(PreparedStatement insert)
protected PreparedStatement
prepare(String insertSQL, SessionImplementor session)
IdentifierGeneratingInsert
prepareIdentifierGeneratingInsert()

Methods inherited from class org.hibernate.id.insert.AbstractReturningDelegate

executeAndExtract, getPersister, performInsert, prepare, releaseStatement

Constructor Details

GetGeneratedKeysDelegate

public GetGeneratedKeysDelegate(PostInsertIdentityPersister persister,
                                Dialect dialect)

Method Details

executeAndExtract

public Serializable executeAndExtract(PreparedStatement insert)
            throws SQLException
Overrides:
executeAndExtract in interface AbstractReturningDelegate

prepare

protected PreparedStatement prepare(String insertSQL,
                                    SessionImplementor session)
            throws SQLException
Overrides:
prepare in interface AbstractReturningDelegate

prepareIdentifierGeneratingInsert

public IdentifierGeneratingInsert prepareIdentifierGeneratingInsert()
Specified by:
prepareIdentifierGeneratingInsert in interface InsertGeneratedIdentifierDelegate