Paginate

public struct Paginate: Fn

Paginate retrieves a page from the set identified by resource. A valid set is any set identifier or instance ref. Instance refs represent singleton sets of themselves.

Reference.

  • Declaration

    Swift

    public init(
            _ resource: Expr,
            before: Expr? = nil,
            after: Expr? = nil,
            ts: Expr? = nil,
            size: Expr? = nil,
            events: Expr? = nil,
            sources: Expr? = nil
        )

    Parameters

    resource

    Resource that contains the set to be paginated.

    before

    Return the previous page of results before this cursor (exclusive).

    after

    Return the next page of results after this cursor (inclusive).

    ts

    If passed, it returns the set at the specified point in time.

    size

    Maximum number of results to return. Default 16.

    events

    If true, return a page from the event history of the set. Default false.

    sources

    If true, include the source sets along with each element. Default false.