Copyright | (c) Anton Gushcha 2016 |
---|---|
License | MIT |
Maintainer | [email protected] |
Stability | experimental |
Portability | Portable |
Safe Haskell | None |
Language | Haskell2010 |
Servant.API.Auth.Token.Pagination
Contents
Description
- type PageParam = QueryParam "page" Page
- type Page = Word
- type PageSizeParam = QueryParam "size" PageSize
- type PageSize = Word
- data PagedList i a = PagedList {
- pagedListItems :: ![WithId i a]
- pagedListPages :: !Word
API types
type PageParam = QueryParam "page" Page Source #
Query parameter that carries pagination page number
type PageSizeParam = QueryParam "size" PageSize Source #
Query parameter that carries pagination page size value
Helpers
Collection of a
with attached ids of type i
and additional
page info.
Constructors
PagedList | |
Fields
|
Instances
(Show i, Show a) => Show (PagedList i a) Source # | |
Generic (PagedList i a) Source # | |
(ToJSON i0, ToJSON a0) => ToJSON (PagedList i0 a0) Source # | |
(FromJSON i0, FromJSON a0) => FromJSON (PagedList i0 a0) Source # | |
(Typeable * i, Typeable * a, ToSchema i, ToSchema a) => ToSchema (PagedList i a) Source # | |
(ToSample i, ToSample a) => ToSample (PagedList i a) Source # | |
type Rep (PagedList i a) Source # | |