package jsont

  1. Overview
  2. Docs
On This Page
  1. Kinds
Declarative JSON data manipulation for OCaml

Install

dune-project
 Dependency

Authors

Maintainers

Sources

jsont-0.2.0.tbz
sha512=6206f73a66cb170b560a72e58f70b9fb2c20397b9ab819dceba49b6602b9b79e47ba307e6910e61ca4694555c66fdcd7a17490afb99548e8f43845a5a88913e7

doc/jsont/Jsont/Sort/index.html

Module Jsont.Sort

Sorts of JSON values.

type t =
  1. | Null
    (*

    Nulls

    *)
  2. | Bool
    (*

    Booleans

    *)
  3. | Number
    (*

    Numbers

    *)
  4. | String
    (*

    Strings

    *)
  5. | Array
    (*

    Arrays

    *)
  6. | Object
    (*

    Objects

    *)

The type for sorts of JSON values.

val to_string : t -> string

to_string sort is a string for sort sort.

val pp : Format.formatter -> t -> unit

pp formats sorts.

Kinds

For formatting error messages.

val or_kind : kind:string -> t -> string

or_kind ~kind sort is to_string sort if kind is "" and kind otherwise.

val kinded : kind:string -> t -> string

kinded ~kind sort is to_string sort if kind is "" and String.concat " " [kind; to_string sort] otherwise.

val kinded' : kind:string -> string -> string

kinded' ~kind sort is sort if kind is "" and String.concat " " [kind; sort] otherwise.