package ocplib-resto

  1. Overview
  2. Docs
val (>>=) : 'a Lwt.t -> ('a -> 'b Lwt.t) -> 'b Lwt.t
val (>|=) : 'a Lwt.t -> ('a -> 'b) -> 'b Lwt.t
module StringMap : sig ... end
type (_, _, _, _, _, _) conv =
  1. | Z : (unit, 'g, 'g, unit, 'f, 'f) conv
  2. | S : ('t, 'g, 'b * 's, 'rt, 'f, 'r) conv -> ('t * 'b, 'g, 's, 'a * 'rt, 'a -> 'f, 'r) conv
val reverse : 'a 'c 'd 'e 'f. ('a, 'c, unit, 'd, 'e, 'f) conv -> 'a -> 'c
val curry : ('a, 'b, unit, 'b, 'c, 'd) conv -> 'c -> 'a -> 'd
module Answer : sig ... end
type step =
  1. | Static of string
  2. | Dynamic of Resto_impl.Arg.descr
type conflict =
  1. | CService
  2. | CDir
  3. | CBuilder
  4. | CCustom
  5. | CTypes of Resto_impl.Arg.descr * Resto_impl.Arg.descr
  6. | CType of Resto_impl.Arg.descr * string list
exception Conflict of step list * conflict
exception Cannot_parse of Resto_impl.Arg.descr * string * string list
module Make (Repr : Json_repr.Repr) : sig ... end
include sig ... end
type !'key directory = 'key Make(Json_repr.Ezjsonm).directory =
  1. | Map : ('key0 -> 'inner_key) * 'inner_key directory -> 'key0 directory
  2. | Static : 'key1 static_directory -> 'key1 directory
  3. | Dynamic : string option * ('key2 -> 'key2 directory Lwt.t) -> 'key2 directory
  4. | Custom : string option * ('key3 -> string list -> custom_lookup Lwt.t) -> 'key3 directory
and !'key static_directory = 'key Make(Json_repr.Ezjsonm).static_directory = {
  1. service : 'key registred_service option;
  2. subdirs : 'key static_subdirectories option;
}
and !'b static_subdirectories = 'b Make(Json_repr.Ezjsonm).static_subdirectories =
  1. | Suffixes : 'key directory StringMap.t -> 'key static_subdirectories
  2. | Arg : 'a Resto_impl.Arg.arg * ('key0 * 'a) directory -> 'key0 static_subdirectories
and !'a registred_service = 'a Make(Json_repr.Ezjsonm).registred_service =
  1. | RegistredService : string option * 'i Json_encoding.encoding * 'o Json_encoding.encoding * ('key -> 'i -> 'o Answer.answer Lwt.t) -> 'key registred_service
val empty : 'a directory
val map_directory : ('a -> 'b) -> 'b directory -> 'a directory
val map_static_directory : ('a -> 'b) -> 'b static_directory -> 'a static_directory
val map_static_subdirectories : ('a -> 'b) -> 'b static_subdirectories -> 'a static_subdirectories
val map_registred_service : ('a -> 'b) -> 'b registred_service -> 'a registred_service
val map : ('a -> 'b) -> 'b directory -> 'a directory
val prefix : ('pr, 'p) Resto_impl.Path.path -> 'p directory -> 'pr directory
val merge_static_directory : step list -> 'p static_directory -> 'p static_directory -> 'p static_directory
val merge : 'a directory -> 'a directory -> 'a directory
val describe_static_directory : bool -> 'a static_directory -> Resto_impl.Description.static_directory_descr
val pp_print_directory : Format.formatter -> 'a directory -> unit
type resolved_directory = Make(Json_repr.Ezjsonm).resolved_directory =
  1. | Dir : 'a directory * 'a -> resolved_directory
val resolve : string list -> 'a directory -> 'a -> string list -> resolved_directory Lwt.t
val describe_directory : ?recurse:bool -> 'a directory -> 'a -> string list -> Resto_impl.Description.directory_descr Lwt.t
val step_of_path : ('a, 'b) Resto_impl.Path.rpath -> step list
val conflict : ('a, 'b) Resto_impl.Path.rpath -> conflict -> 'c
val insert : ('rk, 'k) Resto_impl.Path.rpath -> 'rk directory -> 'k directory * ('k directory -> 'rk directory)
val register : 'pr directory -> ('pr, 'p, 'i, 'o) Resto_impl.service -> ('p -> 'i -> 'o Answer.answer Lwt.t) -> 'pr directory
val register_dynamic_directory : ?descr:string -> 'pr directory -> ('pr, 'a) Resto_impl.Path.path -> ('a -> 'a directory Lwt.t) -> 'pr directory
val register_custom_lookup : ?descr:string -> 'pr directory -> ('pr, 'a) Resto_impl.Path.path -> ('a -> string list -> custom_lookup Lwt.t) -> 'pr directory
val register_describe_directory_service : 'pr directory -> ('pr, 'pr, bool option, Resto_impl.Description.directory_descr) Resto_impl.service -> 'pr directory
val register0 : 'a directory -> ('a, unit, 'b, 'c) Resto_impl.service -> ('b -> 'c Answer.answer Lwt.t) -> 'a directory
val register1 : 'a directory -> ('a, unit * 'b, 'c, 'd) Resto_impl.service -> ('b -> 'c -> 'd Answer.answer Lwt.t) -> 'a directory
val register2 : 'a directory -> ('a, (unit * 'b) * 'c, 'd, 'e) Resto_impl.service -> ('b -> 'c -> 'd -> 'e Answer.answer Lwt.t) -> 'a directory
val register3 : 'a directory -> ('a, ((unit * 'b) * 'c) * 'd, 'e, 'f) Resto_impl.service -> ('b -> 'c -> 'd -> 'e -> 'f Answer.answer Lwt.t) -> 'a directory
val register4 : 'a directory -> ('a, (((unit * 'b) * 'c) * 'd) * 'e, 'f, 'g) Resto_impl.service -> ('b -> 'c -> 'd -> 'e -> 'f -> 'g Answer.answer Lwt.t) -> 'a directory
val register5 : 'a directory -> ('a, ((((unit * 'b) * 'c) * 'd) * 'e) * 'f, 'g, 'h) Resto_impl.service -> ('b -> 'c -> 'd -> 'e -> 'f -> 'g -> 'h Answer.answer Lwt.t) -> 'a directory
val register_dynamic_directory0 : ?descr:string -> 'a directory -> ('a, unit) Resto_impl.Path.path -> unit directory Lwt.t -> 'a directory
val register_dynamic_directory1 : ?descr:string -> 'a directory -> ('a, unit * 'b) Resto_impl.Path.path -> ('b -> (unit * 'b) directory Lwt.t) -> 'a directory
val register_dynamic_directory2 : ?descr:string -> 'a directory -> ('a, (unit * 'b) * 'c) Resto_impl.Path.path -> ('b -> 'c -> ((unit * 'b) * 'c) directory Lwt.t) -> 'a directory
val register_dynamic_directory3 : ?descr:string -> 'a directory -> ('a, ((unit * 'b) * 'c) * 'd) Resto_impl.Path.path -> ('b -> 'c -> 'd -> (((unit * 'b) * 'c) * 'd) directory Lwt.t) -> 'a directory
val register_custom_lookup1 : ?descr:string -> 'a directory -> ('a, unit * 'b) Resto_impl.Path.path -> ('b -> string list -> custom_lookup Lwt.t) -> 'a directory
val register_custom_lookup2 : ?descr:string -> 'a directory -> ('a, (unit * 'b) * 'c) Resto_impl.Path.path -> ('b -> 'c -> string list -> custom_lookup Lwt.t) -> 'a directory
val register_custom_lookup3 : ?descr:string -> 'a directory -> ('a, ((unit * 'b) * 'c) * 'd) Resto_impl.Path.path -> ('b -> 'c -> 'd -> string list -> custom_lookup Lwt.t) -> 'a directory
OCaml

Innovation. Community. Security.