Package org.hibernate.dialect.pagination
Interface LimitHandler
-
- All Known Implementing Classes:
AbstractLimitHandler
,AbstractNoOffsetLimitHandler
,AbstractSimpleLimitHandler
,DB2LimitHandler
,DerbyLimitHandler
,FetchLimitHandler
,LegacyDB2LimitHandler
,LegacyHSQLLimitHandler
,LegacyOracleLimitHandler
,LimitLimitHandler
,LimitOffsetLimitHandler
,NoopLimitHandler
,OffsetFetchLimitHandler
,Oracle12LimitHandler
,SQLServer2005LimitHandler
,SQLServer2012LimitHandler
,TopLimitHandler
public interface LimitHandler
Contract defining dialect-specific limit and offset handling. Most implementations extendAbstractLimitHandler
.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description int
bindLimitParametersAtEndOfQuery(Limit limit, PreparedStatement statement, int index)
int
bindLimitParametersAtStartOfQuery(Limit limit, PreparedStatement statement, int index)
String
processSql(String sql, Limit limit)
default String
processSql(String sql, Limit limit, QueryOptions queryOptions)
void
setMaxRows(Limit limit, PreparedStatement statement)
boolean
supportsLimit()
Does this handler support limiting query results?boolean
supportsLimitOffset()
Does this handler support combinations of limit and offset?boolean
supportsOffset()
Does this handler support offsetting query results without also specifying a limit?
-
-
-
Method Detail
-
supportsLimit
boolean supportsLimit()
Does this handler support limiting query results?- Returns:
- True if this handler supports limit alone.
-
supportsOffset
boolean supportsOffset()
Does this handler support offsetting query results without also specifying a limit?- Returns:
- True if this handler supports offset alone.
-
supportsLimitOffset
boolean supportsLimitOffset()
Does this handler support combinations of limit and offset?- Returns:
- True if the handler supports an offset within the limit support.
-
processSql
default String processSql(String sql, Limit limit, QueryOptions queryOptions)
-
bindLimitParametersAtStartOfQuery
int bindLimitParametersAtStartOfQuery(Limit limit, PreparedStatement statement, int index) throws SQLException
- Throws:
SQLException
-
bindLimitParametersAtEndOfQuery
int bindLimitParametersAtEndOfQuery(Limit limit, PreparedStatement statement, int index) throws SQLException
- Throws:
SQLException
-
setMaxRows
void setMaxRows(Limit limit, PreparedStatement statement) throws SQLException
- Throws:
SQLException
-
-