meltmedia/theoctagon — pull request #1 by MikeChristianson (2014-03-03 04:06:00+00:00)
Title: Added the capability to query the /user endpoint for a paginated list of users

Added the capability to query the persistence layer for a paginated list of any persisted entity type. Default and maximum number of entities per page is defined in AbstractDAO.

### Details on the pagination API
#### It may be used in any of the following ways
* /user (defaults for page and limit are used)
* /user?limit=n (default page is used)
* /user?page=n (default limit is used)
* /user?limit=n&page=m

#### Metadata contained in response headers
* Limit applied to results
* Current page number
* Last page number
* Experimental link to next page

#### Defaults and maximums are specified in AbstractDAO
* Default page is always the first one, 0.
* Default limit is 30. Max limit is 100.

#### Gotchas
* Negative page or limit yields 400 error.
* Max limit applied when exceeded in request.
* Default limit applied when limit 0 is requested.