CursorPage

public struct CursorPage<Element> : CursorPagingCollection, JSONDecodable where Element : CursorPageable, Element : Decodable

A generic collection that provides cursor-based paginated results from a Spotify Web API request.

See also

The Web API Cursor-Based Paging object.
  • Declaration

    Swift

    public var startIndex: Int { get }
  • Declaration

    Swift

    public var endIndex: Int { get }
  • Declaration

    Swift

    public subscript(position: Int) -> Element { get }
  • Declaration

    Swift

    public func index(after i: Int) -> Int
  • Declaration

    Swift

    public func index(before i: Int) -> Int
  • Declaration

    Swift

    public let limit: Int
  • Declaration

    Swift

    public let total: Int?
  • url

    Declaration

    Swift

    public let url: URL
  • Declaration

    Swift

    public let nextURL: URL?
  • Declaration

    Swift

    public let previousURL: URL?
  • A structure containing a set of cursors used to identify items in a cursor-based paging collection.

    Cursor-based paging collections depend on a set of cursors to identify the first and last items in a given page, providing reference points from which to page through a larger list of results, typically sorted in chronological order.

    See more

    Declaration

    Swift

    public struct Cursors : CursorProtocol, Decodable
  • Declaration

    Swift

    public let cursors: Cursors