package eliom

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
val section : Lwt_log_core.section
type params = (string * Eliommod_parameters.param) list
type params' = (string * string) list
type +'a param_name = string

Type of names in a form

type no_param_name

empty type used when it is not possible to use the parameter in a form

type ('a, 'b) binsum =
  1. | Inj1 of 'a
  2. | Inj2 of 'b
type 'an listnames = {
  1. it : 'el 'a. ('an -> 'el -> 'a -> 'a) -> 'el list -> 'a -> 'a;
}
type coordinates = {
  1. abscissa : int;
  2. ordinate : int;
}
type 'a setoneradio = [
  1. | `Set of 'a
  2. | `One of 'a
  3. | `Radio of 'a
]
type 'a oneradio = [
  1. | `One of 'a
  2. | `Radio of 'a
]
type 'a setone = [
  1. | `Set of 'a
  2. | `One of 'a
]
type 'a to_and_of = 'a Eliom_common.to_and_of = {
  1. of_string : string -> 'a;
  2. to_string : 'a -> string;
}
type _ atom =
  1. | TFloat : float atom
  2. | TInt : int atom
  3. | TInt32 : int32 atom
  4. | TInt64 : int64 atom
  5. | TNativeint : nativeint atom
  6. | TBool : bool atom
  7. | TString : string atom
val string_of_atom : 'a atom -> 'a0 -> string
val atom_of_string : 'a atom -> string -> 'a0
val to_from_of_atom : 'a atom -> 'b to_and_of
type 'a filter = ('a -> unit) option
type raw = Eliom_request_info.raw_post_data
type 'a ocaml = string
type suff = [
  1. | `WithoutSuffix
  2. | `WithSuffix
  3. | `Endsuffix
]
type (_, _) params_type_ =
  1. | TProd : (('a, 'an) params_type_ * ('b, 'bn) params_type_) -> ('a * 'b, 'an * 'bn) params_type_
  2. | TOption : (('a, 'an) params_type_ * bool) -> ('a option, 'an) params_type_
  3. | TList : (string * ('a, 'an) params_type_) -> ('a list, 'an listnames) params_type_
  4. | TSet : ('a, [ `One of 'an ] param_name) params_type_ -> ('a list, [ `Set of 'an ] param_name) params_type_
  5. | TSum : (('a, 'an) params_type_ * ('b, 'bn) params_type_) -> (('a, 'b) binsum, 'an * 'bn) params_type_
  6. | TAtom : (string * 'a atom) -> ('a, [ `One of 'a ] param_name) params_type_
  7. | TCoord : string -> (coordinates, [ `One of coordinates ] param_name) params_type_
  8. | TFile : string -> (Eliom_lib.file_info, [ `One of Eliom_lib.file_info ] param_name) params_type_
  9. | TUserType : (string * 'a Eliom_common.To_and_of_shared.t) -> ('a, [ `One of 'a ] param_name) params_type_
  10. | TTypeFilter : (('a, 'an) params_type_ * 'a filter) -> ('a, 'an) params_type_
  11. | TESuffix : string -> (string list, [ `One of string list ] param_name) params_type_
  12. | TESuffixs : string -> (string, [ `One of string ] param_name) params_type_
  13. | TESuffixu : (string * 'a Eliom_common.To_and_of_shared.t) -> ('a, [ `One of 'a ] param_name) params_type_
  14. | TSuffix : (bool * ('s, 'sn) params_type_) -> ('s, 'sn) params_type_
  15. | TUnit : (unit, unit) params_type_
  16. | TAny : ((string * string) list, unit) params_type_
  17. | TConst : string -> (unit, [ `One of unit ] param_name) params_type_
  18. | TNLParams : ('a, 'names) non_localized_params_ -> ('a, 'names) params_type_
  19. | TJson : (string * 'a Deriving_Json.t option) -> ('a, [ `One of 'a ocaml ] param_name) params_type_
  20. | TRaw_post_data : (raw, no_param_name) params_type_
and ('a, 'names) non_localized_params_ = {
  1. name : string;
  2. persistent : bool;
  3. get : 'a option Polytables.key;
  4. post : 'a option Polytables.key;
  5. param : ('a, 'names) params_type_;
}
type ('a, +'suff, 'an) non_localized_params = ('a, 'an) non_localized_params_ constraint 'suff = [< suff ]
type ('a, +'suff, 'an) params_type = ('a, 'an) params_type_ constraint 'suff = [< suff ]
val int : string -> (int, [ `One of int ] param_name) params_type_
val int32 : string -> (int32, [ `One of int32 ] param_name) params_type_
val int64 : string -> (int64, [ `One of int64 ] param_name) params_type_
val float : string -> (float, [ `One of float ] param_name) params_type_
val bool : string -> (bool, [ `One of bool ] param_name) params_type_
val string : string -> (string, [ `One of string ] param_name) params_type_
val unit : (unit, unit) params_type_
val coordinates : string -> (coordinates, [ `One of coordinates ] param_name) params_type_
val type_checker : ('a -> unit) -> ('b, 'c) params_type_ -> ('b, 'c) params_type_
val sum : ('a, 'b) params_type_ -> ('c, 'd) params_type_ -> (('a, 'c) binsum, 'b * 'd) params_type_
val prod : ('a, 'b) params_type_ -> ('c, 'd) params_type_ -> ('a * 'c, 'b * 'd) params_type_
val (**) : ('a, 'b) params_type_ -> ('c, 'd) params_type_ -> ('a * 'c, 'b * 'd) params_type_
val opt : ('a, 'b) params_type_ -> ('a option, 'b) params_type_
val neopt : ('a, 'b) params_type_ -> ('a option, 'b) params_type_
val radio : (string -> ('a, 'b) params_type_) -> string -> ('a option, 'b) params_type_
val list : string -> ('a, 'b) params_type_ -> ('a list, 'b listnames) params_type_
val set : (string -> ('a, [ `One of 'b ] param_name) params_type_) -> string -> ('a list, [ `Set of 'b ] param_name) params_type_
val any : ((string * string) list, unit) params_type_
val suffix_const : string -> (unit, [ `One of unit ] param_name) params_type_
val all_suffix : string -> (string list, [ `One of string list ] param_name) params_type_
val all_suffix_string : string -> (string, [ `One of string ] param_name) params_type_
val suffix : ?redirect_if_not_suffix:bool -> ('a, 'b) params_type_ -> ('a, 'b) params_type_
val suffix_prod : ?redirect_if_not_suffix:bool -> ('s, [< `Endsuffix | `WithoutSuffix ], 'sn) params_type -> ('a, [ `WithoutSuffix ], 'an) params_type -> ('s0 * 'a0, [ `WithSuffix ], 'sn0 * 'an0) params_type
val ocaml : string -> 'a Deriving_Json.t -> ('a, [ `One of 'a ocaml ] param_name) params_type_
val raw_post_data : (raw, no_param_name) params_type_
val make_list_suffix : int -> string
val make_suffix : 'a 'c. ('a, [< suff ], 'c) params_type -> 'a -> string list
val aux : 'a 'c. ('a, [< suff ], 'c) params_type -> string list option -> (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t -> 'a -> string -> string -> (string * Eliommod_parameters.field) list -> string list option * (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t * (string * Eliommod_parameters.field) list
val construct_params_list_raw : (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t -> ('a, [< suff ], 'b) params_type -> 'c -> string list option * (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t * (string * Eliommod_parameters.field) list
val get_to_and_of : 'a 'c. ('a, [< suff ], 'c) params_type -> 'a to_and_of

Given a parameter type, get the two functions that converts from and to strings. You should only use this function on

  • options ;
  • basic types : int, int32, int64, float, string
  • marshal
  • unit
  • string
  • bool
val walk_parameter_tree : 'a 'c. string -> ('a, [< suff ], 'c) params_type -> 'a to_and_of option

Walk the parameter tree to search for a parameter, given its name

val construct_params_string : (string * Eliommod_parameters.field) list -> string
val construct_params_list : (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t -> ('a, [< suff ], 'b) params_type -> 'c -> string list option * (string * Eliommod_parameters.field) list
val construct_params : (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t -> ('a, [< suff ], 'b) params_type -> 'c -> string list option * string
val make_params_names : ('a, [< suff ], 'b) params_type -> bool * 'b
val string_of_param_name : 'a -> 'a
val add_pref_params : 'a 'c. string -> ('a, [< suff ] as 'b, 'c) params_type -> ('a, 'b, 'c) params_type
val nl_prod : ('a, [< suff ] as 'b, 'an) params_type -> ('s, [ `WithoutSuffix ], 'sn) non_localized_params -> ('a0 * 's0, 'c, 'an0 * 'sn0) params_type
val remove_from_nlp : 'a 'c. 'b Eliom_lib.String.Table.t -> ('a, [< suff ], 'c) params_type -> 'b Eliom_lib.String.Table.t
type nl_params_set = (string * Eliommod_parameters.param) list Eliom_lib.String.Table.t
val empty_nl_params_set : 'a Eliom_lib.String.Table.t
val add_nl_parameter : nl_params_set -> ('a, 'b) non_localized_params_ -> 'c -> nl_params_set
val table_of_nl_params_set : 'a -> 'a
val list_of_nl_params_set : (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t -> (string * Eliommod_parameters.field) list
val string_of_nl_params_set : (string * Eliommod_parameters.field) list Eliom_lib.String.Table.t -> string
val get_nl_params_names : ('a, 'b) non_localized_params_ -> 'c
val make_nlp_name : bool -> string -> string -> string
val make_non_localized_parameters : prefix:string -> name:string -> ?persistent:bool -> ('a, [ `WithoutSuffix ], 'b) params_type -> ('a0, [ `WithoutSuffix ], 'b0) non_localized_params
val contains_suffix : 'a 'c. ('a, [< suff ], 'c) params_type -> bool option
val wrap_param_type : 'a 'c. ('a, [< suff ] as 'b, 'c) params_type -> ('a, 'b, 'c) params_type
type _ is_unit =
  1. | U_not : _ is_unit
  2. | U_yes : unit is_unit
val is_unit : 'a 'c. ('a, [< suff ], 'c) params_type -> 'a is_unit
type anon_params_type = int
val anonymise_params_type : ('a, [< suff ], 'c) params_type -> anon_params_type
type files = (string * Eliom_lib.file_info) list
type +'a res_reconstr_param =
  1. | Res_ of 'a * params' * files
  2. | Errors_ of (string * string * exn) list * params' * files
val end_of_list : (string * 'a) list -> string -> bool
val reconstruct_params_ : ('a, [< suff ], 'b) params_type -> params' -> files -> bool -> string list option -> 'a0
val reconstruct_params : sp:unit -> ('a, [< suff ], 'c) params_type -> params' Lwt.t option -> files Lwt.t option -> bool -> string list option -> 'a0 Lwt.t
OCaml

Innovation. Community. Security.