Pagination
Certain API operations return lists of objects. When the number of objects in the list is large, the API will paginate the results.
The Files.com DotNet SDK provides multiple ways to paginate through lists of objects.
Creating a list, such as client.Folders.ListFor("/"), sends no request; pages are requested as you
load them. Every page comes from the client the list was made with. Lists made with static methods,
such as Folder.ListFor("/"), use the default client.
Automatic Pagination
The ListAutoPaging method automatically paginates and loads each page into memory.
Pass a CancellationToken to stop before the next page is loaded. With a token, failures are thrown as they
are, such as NotFoundException or OperationCanceledException. Without one, they are wrapped in an
AggregateException.
Manual Pagination
The LoadNextPageAsync/HasNextPage methods allow for manual pagination and loading of each page into memory.
Load All Items
The AllAsync method loads all items into memory.