Package com.helixframework.api.contract
Class OffsetPaginatedResponse<T>
java.lang.Object
com.helixframework.api.contract.OffsetPaginatedResponse<T>
- Type Parameters:
T- item type
API response that returns a collection with offset pagination.
-
Constructor Summary
ConstructorsConstructorDescriptionCreates an instance ofOffsetPaginatedResponse.OffsetPaginatedResponse(long offset, long limit, Collection<T> items) Creates an instance ofOffsetPaginatedResponse. -
Method Summary
-
Constructor Details
-
OffsetPaginatedResponse
public OffsetPaginatedResponse()Creates an instance ofOffsetPaginatedResponse. -
OffsetPaginatedResponse
Creates an instance ofOffsetPaginatedResponse.- Parameters:
offset- page offsetlimit- page limititems- items to return in response
-
-
Method Details
-
getCount
public int getCount()Gets the number of items in the collection.- Returns:
- number of items in the collection
-
getOffset
Gets the pagination offset. The total number of records to offset before beginning to return results.- Returns:
- pagination offset
-
getLimit
Gets the page limit. The total number of results to return.- Returns:
- page limit
-
getItems
Gets the items.- Returns:
- items
-