Module Odoc_xref2.EnvSource
Source
type resolver = {open_units : string list;lookup_unit : Odoc_xref2.Env.path_query -> (Odoc_xref2.Env.lookup_unit_result, Odoc_xref2.Env.lookup_error) Stdlib.result;lookup_page : Odoc_xref2.Env.path_query -> (Odoc_model.Lang.Page.t, Odoc_xref2.Env.lookup_error) Stdlib.result;lookup_asset : Odoc_xref2.Env.path_query -> (Odoc_model.Lang.Asset.t, Odoc_xref2.Env.lookup_error) Stdlib.result;lookup_impl : string -> Odoc_model.Lang.Implementation.t option;
}Source
type root = | Resolved of Odoc_model.Root.t * Odoc_model.Paths.Identifier.Module.t * Odoc_xref2.Component.Module.t| Forward
Source
type lookup_type = | Module of Odoc_model.Paths.Identifier.Path.Module.t| ModuleType of Odoc_model.Paths.Identifier.ModuleType.t| RootModule of Odoc_model.Names.ModuleName.t * [ `Forward | `Resolved of Stdlib.Digest.t ] option| ModuleByName of string * Odoc_model.Paths.Identifier.Path.Module.t| FragmentRoot of int
module LookupTypeSet : Stdlib.Set.S with type elt = Odoc_xref2.Env.lookup_typeSource
val with_recorded_lookups :
Odoc_xref2.Env.t ->
(Odoc_xref2.Env.t -> 'a) ->
Odoc_xref2.Env.LookupTypeSet.t * 'aSource
val add_fragment_root :
Odoc_xref2.Component.Signature.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_type :
Odoc_model.Paths.Identifier.Type.t ->
Odoc_xref2.Component.TypeDecl.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_module_type :
Odoc_model.Paths.Identifier.Path.ModuleType.t ->
Odoc_xref2.Component.ModuleType.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_value :
Odoc_model.Paths.Identifier.Value.t ->
Odoc_xref2.Component.Value.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_label :
Odoc_model.Paths.Identifier.Label.t ->
Odoc_xref2.Component.Label.t ->
Odoc_xref2.Env.t ->
unboxed:bool ->
Odoc_xref2.Env.tSource
val add_class :
Odoc_model.Paths.Identifier.Class.t ->
Odoc_xref2.Component.Class.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_class_type :
Odoc_model.Paths.Identifier.ClassType.t ->
Odoc_xref2.Component.ClassType.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_exception :
Odoc_model.Paths.Identifier.Exception.t ->
Odoc_xref2.Component.Exception.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_extension_constructor :
Odoc_model.Paths.Identifier.Extension.t ->
Odoc_xref2.Component.Extension.Constructor.t ->
Odoc_xref2.Component.Extension.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_method :
Odoc_model.Paths.Identifier.Method.t ->
Odoc_xref2.Component.Method.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_module_functor_args :
Odoc_xref2.Component.Module.t ->
Odoc_model.Paths.Identifier.Path.Module.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val add_module_type_functor_args :
Odoc_xref2.Component.ModuleType.t ->
Odoc_model.Paths.Identifier.ModuleType.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val lookup_fragment_root :
Odoc_xref2.Env.t ->
(int * Odoc_xref2.Component.Signature.t) optionSource
val lookup_page_by_name :
string ->
Odoc_xref2.Env.t ->
(Odoc_model.Lang.Page.t, Odoc_xref2.Env.lookup_error) Stdlib.resultSource
val lookup_page_by_path :
Odoc_model.Paths.Reference.Hierarchy.t ->
Odoc_xref2.Env.t ->
(Odoc_model.Lang.Page.t, Odoc_xref2.Env.lookup_error) Stdlib.resultSource
val lookup_asset_by_path :
Odoc_model.Paths.Reference.Hierarchy.t ->
Odoc_xref2.Env.t ->
(Odoc_model.Lang.Asset.t, Odoc_xref2.Env.lookup_error) Stdlib.resultSource
val lookup_asset_by_name :
string ->
Odoc_xref2.Env.t ->
(Odoc_model.Lang.Asset.t, Odoc_xref2.Env.lookup_error) Stdlib.resultSource
val lookup_unit_by_path :
Odoc_model.Paths.Reference.Hierarchy.t ->
Odoc_xref2.Env.t ->
(Odoc_xref2.Component.Element.module_, Odoc_xref2.Env.lookup_error)
Stdlib.resultSource
val lookup_root_module :
Odoc_model.Names.ModuleName.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.root optionTarget of a lookup
Source
val lookup_by_name :
'a Odoc_xref2.Env.scope ->
string ->
Odoc_xref2.Env.t ->
'a Odoc_xref2.Env.maybe_ambiguousLookup an element in Env depending on the given scope. Return Error (`Ambiguous _) when two or more elements match the given scope and name.
Source
val lookup_by_id :
'a Odoc_xref2.Env.scope ->
[< Odoc_model.Paths.Identifier.t_pv ] Odoc_model.Paths.Identifier.id ->
Odoc_xref2.Env.t ->
'a optionLike lookup_by_name but use an identifier as key.
Source
val s_fragment_type_parent :
Odoc_xref2.Component.Element.fragment_type_parent Odoc_xref2.Env.scopeSource
val add_functor_parameter :
Odoc_model.Lang.FunctorParameter.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val open_class_signature :
Odoc_model.Lang.ClassSignature.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val open_type_substitution :
Odoc_model.Lang.TypeDecl.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val open_module_substitution :
Odoc_model.Lang.ModuleSubstitution.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tSource
val open_module_type_substitution :
Odoc_model.Lang.ModuleTypeSubstitution.t ->
Odoc_xref2.Env.t ->
Odoc_xref2.Env.tAdd a page content to the env.
Source
val env_of_unit :
Odoc_model.Lang.Compilation_unit.t ->
linking:bool ->
Odoc_xref2.Env.resolver ->
Odoc_xref2.Env.tCreate a new env with a module initially opened.
Create a new env for a page.
Source
val env_of_impl :
Odoc_model.Lang.Implementation.t ->
Odoc_xref2.Env.resolver ->
Odoc_xref2.Env.tCreate a new env for an implementation.
Create a new env for a reference.
Create a new env for testing purposes
Create an empty environment reusing the same resolver.