public abstract class

AbstractReturningDelegate

extends Object
implements InsertGeneratedIdentifierDelegate
java.lang.Object
   ↳ org.hibernate.id.insert.AbstractReturningDelegate
Known Direct Subclasses

Class Overview

Abstract InsertGeneratedIdentifierDelegate implementation where the underlying strategy causes the enerated identitifer to be returned as an effect of performing the insert statement. Thus, there is no need for an additional sql statement to determine the generated identitifer.

Summary

Public Constructors
AbstractReturningDelegate(PostInsertIdentityPersister persister)
Public Methods
final Serializable performInsert(String insertSQL, SessionImplementor session, Binder binder)
Perform the indicated insert SQL statement and determine the identifier value generated.
Protected Methods
abstract Serializable executeAndExtract(PreparedStatement insert)
PostInsertIdentityPersister getPersister()
abstract PreparedStatement prepare(String insertSQL, SessionImplementor session)
void releaseStatement(PreparedStatement insert, SessionImplementor session)
[Expand]
Inherited Methods
From class java.lang.Object
From interface org.hibernate.id.insert.InsertGeneratedIdentifierDelegate

Public Constructors

public AbstractReturningDelegate (PostInsertIdentityPersister persister)

Public Methods

public final Serializable performInsert (String insertSQL, SessionImplementor session, Binder binder)

Perform the indicated insert SQL statement and determine the identifier value generated.

Parameters
insertSQL The INSERT statement string
session The session in which we are operating
binder The param binder
Returns
  • The generated identifier value.

Protected Methods

protected abstract Serializable executeAndExtract (PreparedStatement insert)

Throws
SQLException

protected PostInsertIdentityPersister getPersister ()

protected abstract PreparedStatement prepare (String insertSQL, SessionImplementor session)

Throws
SQLException

protected void releaseStatement (PreparedStatement insert, SessionImplementor session)

Throws
SQLException