Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrInvalidOffsetParameter represents an error case where an invalid offset value is provided ErrInvalidOffsetParameter = errors.New("invalid offset query parameter") // ErrOffsetOverTotalCount represents an error case where the given offset value is larger than the total count ErrOffsetOverTotalCount = errors.New("offset query parameter is larger than the total count of jobs") // ErrInvalidLimitParameter represents an error case where an invalid limit value is provided ErrInvalidLimitParameter = errors.New("invalid limit query parameter") // ErrLimitOverMax represents an error case where the given limit value is larger than the maximum allowed ErrLimitOverMax = errors.New("limit query parameter is larger than the maximum allowed") )
Functions ¶
This section is empty.
Types ¶
type PaginatedResponse ¶
type PaginatedResponse struct { Count int `json:"count"` Offset int `json:"offset"` Limit int `json:"limit"` TotalCount int `json:"total_count"` }
PaginatedResponse represents the pagination related values that go into list based response
type Paginator ¶
Paginator is a type to hold pagination related defaults, and provides helper functions using the defaults if needed
func NewPaginator ¶
NewPaginator creates a new instance
Click to show internal directories.
Click to hide internal directories.