Class PaginationContext
- java.lang.Object
-
- org.apache.shardingsphere.infra.binder.segment.select.pagination.PaginationContext
-
public final class PaginationContext extends Object
Pagination context.
-
-
Constructor Summary
Constructors Constructor Description PaginationContext(org.apache.shardingsphere.sql.parser.sql.common.segment.dml.pagination.PaginationValueSegment offsetSegment, org.apache.shardingsphere.sql.parser.sql.common.segment.dml.pagination.PaginationValueSegment rowCountSegment, List<Object> params)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longgetActualOffset()Get actual offset.Optional<Long>getActualRowCount()Get actual row count.Optional<Integer>getOffsetParameterIndex()Get offset parameter index.Optional<org.apache.shardingsphere.sql.parser.sql.common.segment.dml.pagination.PaginationValueSegment>getOffsetSegment()Get offset segment.longgetRevisedOffset()Get revised offset.longgetRevisedRowCount(SelectStatementContext selectStatementContext)Get revised row count.Optional<Integer>getRowCountParameterIndex()Get row count parameter index.Optional<org.apache.shardingsphere.sql.parser.sql.common.segment.dml.pagination.PaginationValueSegment>getRowCountSegment()Get row count segment.
-
-
-
Method Detail
-
getOffsetSegment
public Optional<org.apache.shardingsphere.sql.parser.sql.common.segment.dml.pagination.PaginationValueSegment> getOffsetSegment()
Get offset segment.- Returns:
- offset segment
-
getRowCountSegment
public Optional<org.apache.shardingsphere.sql.parser.sql.common.segment.dml.pagination.PaginationValueSegment> getRowCountSegment()
Get row count segment.- Returns:
- row count segment
-
getActualOffset
public long getActualOffset()
Get actual offset.- Returns:
- actual offset
-
getActualRowCount
public Optional<Long> getActualRowCount()
Get actual row count.- Returns:
- actual row count
-
getOffsetParameterIndex
public Optional<Integer> getOffsetParameterIndex()
Get offset parameter index.- Returns:
- offset parameter index
-
getRowCountParameterIndex
public Optional<Integer> getRowCountParameterIndex()
Get row count parameter index.- Returns:
- row count parameter index
-
getRevisedOffset
public long getRevisedOffset()
Get revised offset.- Returns:
- revised offset
-
getRevisedRowCount
public long getRevisedRowCount(SelectStatementContext selectStatementContext)
Get revised row count.- Parameters:
selectStatementContext- select statement context- Returns:
- revised row count
-
-