Record Class FollowOnLockingRequest
java.lang.Object
java.lang.Record
org.hibernate.dialect.lock.spi.FollowOnLockingRequest
- Record Components:
sql- the completed SQL considered for executionstatementShape- known structural characteristics of the SQL statementpagination- effective pagination characteristicslockKind- requested pessimistic lock kindtimeout- effective lock timeoutscope- requested pessimistic lock scoperawSqlRewriteOutcome- outcome of any already-rendered SQL rewrite
@SPI
public record FollowOnLockingRequest(String sql, FollowOnLockingRequest.StatementShape statementShape, FollowOnLockingRequest.Pagination pagination, PessimisticLockKind lockKind, Timeout timeout, PessimisticLockScope scope, LockingSqlRewriteResult.Outcome rawSqlRewriteOutcome)
extends Record
The immutable facts used to decide whether a completed SQL statement requires follow-on locking.
Hibernate creates this request after SQL rendering and any raw-SQL locking
attempt. A FollowOnLockingPolicy should make its decision only from these
stable facts and must not retain the request.
- Since:
- 8.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final recordEffective pagination characteristics of the completed statement.static final recordKnown structural characteristics of the completed statement. -
Constructor Summary
ConstructorsConstructorDescriptionFollowOnLockingRequest(String sql, FollowOnLockingRequest.StatementShape statementShape, FollowOnLockingRequest.Pagination pagination, PessimisticLockKind lockKind, Timeout timeout, PessimisticLockScope scope, LockingSqlRewriteResult.Outcome rawSqlRewriteOutcome) Creates a complete follow-on locking request. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.lockKind()Returns the value of thelockKindrecord component.Returns the value of thepaginationrecord component.Returns the value of therawSqlRewriteOutcomerecord component.scope()Returns the value of thescoperecord component.sql()Returns the value of thesqlrecord component.Returns the value of thestatementShaperecord component.timeout()Returns the value of thetimeoutrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
FollowOnLockingRequest
public FollowOnLockingRequest(String sql, FollowOnLockingRequest.StatementShape statementShape, FollowOnLockingRequest.Pagination pagination, PessimisticLockKind lockKind, Timeout timeout, PessimisticLockScope scope, LockingSqlRewriteResult.Outcome rawSqlRewriteOutcome) Creates a complete follow-on locking request.
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
sql
-
statementShape
Returns the value of thestatementShaperecord component.- Returns:
- the value of the
statementShaperecord component
-
pagination
Returns the value of thepaginationrecord component.- Returns:
- the value of the
paginationrecord component
-
lockKind
-
timeout
-
scope
-
rawSqlRewriteOutcome
Returns the value of therawSqlRewriteOutcomerecord component.- Returns:
- the value of the
rawSqlRewriteOutcomerecord component
-