boto/botocore — pull request #88 by jamesls (2013-07-25 16:35:23+00:00)
Title: Add starting_token and max_items to paginators

When calling .paginate() on an operation you can specify two
additional parameters:

* starting_token - Indicates where to start in the pagination
* max_items - Indicates the total number of results to return.

The results are based on the primary result key (the first item
if there are more than one result key).

Also, we expose a `resume_token` property that presents an opaque
token the user can specify in subsequent requests via `start_token` that
instructs the paginator where to pick up. This works with multiple input
tokens as well as indexing into an existing page. This means that
the user only has to deal with a single `resume_token` instead of
multiple next tokens as well as an index. `build_full_result` was
also updated to inject this arg as `NextToken` into the complete
response.

As part of this change, the pagination results always return a dictionary,
even if there is only a single result key.

cc @garnaat @toastdriven