Documentation ¶
Index ¶
- func NextPageToken(req pagination.Request, resultSize int32, minps int32, maxps int32) (string, error)
- func ParseAndValidateOrderBy(req ordering.Request) (map[string]string, error)
- func ParseAndValidatePageSize(req pagination.Request, minPageSize int32, maxPageSize int32) (int32, error)
- func ParseAndValidatePageToken(req pagination.Request) (pagination.PageToken, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NextPageToken ¶
func NextPageToken(req pagination.Request, resultSize int32, minps int32, maxps int32) (string, error)
*
Create next page token from page size and previous page token For more - https://google.aip.dev/158
*
func ParseAndValidateOrderBy ¶
*
Extract order by from request and parse it and convert into a map of field and order. Eg: Name desc Age Salary desc For more - https://google.aip.dev/132
*
func ParseAndValidatePageSize ¶
func ParseAndValidatePageSize(req pagination.Request, minPageSize int32, maxPageSize int32) (int32, error)
*
Extract page size from request and maps it between min page size and max page size if not in range. For more - https://google.aip.dev/158
*
func ParseAndValidatePageToken ¶
func ParseAndValidatePageToken(req pagination.Request) (pagination.PageToken, error)
*
Extract page token from request and parse it. For more - https://google.aip.dev/158
*
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.