blob: 33d9bc81caed55a47c6ad79cab7c768d0225c17f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
|
type setting
type list' = { id : string; source : string }
val init : unit -> setting
val get_content :
setting -> Model.Identifier.t -> Model.Reference.t Model.Content.t option
(** Get the content from the setting. *)
val root_contents : setting -> Model.Reference.t Model.Content.t list
(** Extract all the content in the topological order.
Only the root content are repored in the list *)
val register_content :
'a Type.Id.t -> setting -> ('a * Model.Identifier.t) Model.Content.t -> unit
(** Register a content and all the associated subcontent in the top level,
giving the possibility to fetch any content or subcontent by is’s name
without traversing the whole tree each time. *)
exception BrokenLink : ('a Type.Id.t * 'a * Model.Identifier.t) -> exn
(** Exception raised when a reference in the configuration targets a
non-existing content *)
exception NotImplemented : ('a Type.Id.t * 'a * Model.Identifier.t) -> exn
val register_list : setting -> list' -> setting
val check : setting -> (unit, exn) result
(** Check the setting and return the the error as an exception *)
val tree : ?required:bool -> setting -> Graph_tree.t
val escaped : string -> string
|