package spotify-web-api

  1. Overview
  2. Docs
type 'a paging = 'a Paging_t.paging = {
  1. href : string;
  2. items : 'a list;
  3. limit : int;
  4. offset : int;
  5. total : int;
}
val write_paging : (Buffer.t -> 'a -> unit) -> Buffer.t -> 'a paging -> unit

Output a JSON value of type paging.

val string_of_paging : (Buffer.t -> 'a -> unit) -> ?len:int -> 'a paging -> string

Serialize a value of type paging into a JSON string.

  • parameter len

    specifies the initial length of the buffer used internally. Default: 1024.

Input JSON data of type paging.

val paging_of_string : (Yojson.Safe.lexer_state -> Lexing.lexbuf -> 'a) -> string -> 'a paging

Deserialize JSON data of type paging.

OCaml

Innovation. Community. Security.