module Template: Web__Templatetype parsed_info
typetemplate = privateparsed_info * string
val parsed_info_revision : intThe revision number of the representation of parsed_info.
It should be checked before unmarshaling parsed_info.
exception Parse_failure of int * string
val parse_substring : string -> int -> int -> template
val parse_string : string -> templateParse a string to template.
Parse_failure (positon, message)val repair : parsed_info * string -> templateA template can be marshaled separately as parsed_info and a source string.
repair (p, s) checks p is a result parsed from s and coercions its
type to restore the template.
val is_empty : template -> boolTest whether a template is empty or not.
val kind : template -> [ `attribute | `element ]Returns the kind of a template.
val find_opt : template -> string -> template optionfind_opt tag template returns Some subtemplate named tag of
template, or None if tag does not exist.
val find : template -> string -> templatefind tag template returns the subtemplate named tag of template.
Not_found if tag does not existexception Unhandled_tag of string
val unhandled : string -> 'aThe dummy handler for output_template_with and output_subtemplate_with.
Unhandled_tag tag by unhandled tag ...exception Not_found_tag of string
val output_template_with : (string ->
'a -> (string -> int -> int -> unit) -> template -> 'a) ->
'a -> (string -> int -> int -> unit) -> template -> 'aoutput_template_with f acc print_substring template outputs the contents
of template with print_substring.
f is callbacked with acc for each subtemplate.
val output_subtemplate_with : (string ->
'a -> (string -> int -> int -> unit) -> template -> 'a) ->
'a ->
(string -> int -> int -> unit) -> template -> string -> 'aoutput_subtemplate_with f acc print_substring template tag roughly does
output_template_with f acc print_substring (find template tag).
Not_found_tag tag instead of Not_foundval output_template : (string -> int -> int -> unit) -> template -> unitNo handler variation of output_template_with.
If a template has subtemplate, it applys unhandled.
val output_subtemplate : (string -> int -> int -> unit) -> template -> string -> unitNo handler variation of output_subtemplate_with.