Page¶
-
class
faunadb.page.Page(data, before=None, after=None)¶ Represents a single pagination result. See
paginatein the docs. You must convert to Page yourself usingfrom_raw().-
__init__(data, before=None, after=None)¶
-
data= None¶ List of elements returned by the query.
-
static
from_raw(raw)¶ Convert a raw response dict to a Page.
-
map_data(func)¶ Return a new Page whose data has had
funcapplied to each element.
-
static
set_iterator(client, set_query, map_lambda=None, mapper=None, page_size=None)¶ Iterator that keeps getting new pages of a set.
Parameters: - map_lambda – If present, a
lambda_exprfor mapping set elements. - mapper – Mapping Python function used on each page element.
- page_size – Number of instances to be fetched at a time.
Returns: Iterator through all elements in the set.
- map_lambda – If present, a
-