Package com.helixframework.db.repository
Interface MappingOffsetQuerySpecification<R>
- Type Parameters:
R- the type of object to be mapped from the ResultSet
- All Superinterfaces:
QuerySpecification<R>
MappingOffsetQuerySpecification represents a query specification with offset-based pagination functionality and mapping capabilities.
It extends the QuerySpecification interface.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final longDefault limit value for a query specification.static final longDefault offset value for a query specification.static final com.helixframework.pagination.sort.SortOrderDefault sort order value for a query specification. -
Method Summary
Modifier and TypeMethodDescriptiondefault longgetLimit()Retrieves the limit of the query.Retrieves theResultSetMapperassociated with this query specification.default longRetrieves the offset of the query.default com.helixframework.pagination.sort.SortOrderRetrieves the sort order of the query.Methods inherited from interface com.helixframework.db.repository.QuerySpecification
execute, getName, getTxId
-
Field Details
-
DEFAULT_LIMIT
static final long DEFAULT_LIMITDefault limit value for a query specification.- See Also:
-
DEFAULT_OFFSET
static final long DEFAULT_OFFSETDefault offset value for a query specification.- See Also:
-
DEFAULT_SORT_ORDER
static final com.helixframework.pagination.sort.SortOrder DEFAULT_SORT_ORDERDefault sort order value for a query specification. The default sort order is set to ASCENDING.
-
-
Method Details
-
getLimit
default long getLimit()Retrieves the limit of the query.- Returns:
- the limit of the query
-
getOffset
default long getOffset()Retrieves the offset of the query.- Returns:
- the offset of the query
-
getSortOrder
default com.helixframework.pagination.sort.SortOrder getSortOrder()Retrieves the sort order of the query.- Returns:
- the sort order of the query
-
getMapper
ResultSetMapper<R> getMapper()Retrieves theResultSetMapperassociated with this query specification. Use theResultSetMapperto map aResultSetto an object or a list of objects.- Returns:
- the
ResultSetMapperassociated with this query specification
-