package opam-solver

  1. Overview
  2. Docs

Module type OpamActionGraph.SIGSource

Sourcetype package
include OpamParallel.GRAPH with type V.t = package OpamTypes.action
Sourcetype t
Sourcemodule V : sig ... end
Sourcetype vertex = V.t
Sourcemodule E : sig ... end
Sourcetype edge = E.t
Sourceval is_directed : bool
Sourceval is_empty : t -> bool
Sourceval nb_vertex : t -> int
Sourceval nb_edges : t -> int
Sourceval out_degree : t -> vertex -> int
Sourceval in_degree : t -> vertex -> int
Sourceval mem_vertex : t -> vertex -> bool
Sourceval mem_edge : t -> vertex -> vertex -> bool
Sourceval mem_edge_e : t -> edge -> bool
Sourceval find_edge : t -> vertex -> vertex -> edge
Sourceval find_all_edges : t -> vertex -> vertex -> edge list
Sourceval succ : t -> vertex -> vertex list
Sourceval pred : t -> vertex -> vertex list
Sourceval succ_e : t -> vertex -> edge list
Sourceval pred_e : t -> vertex -> edge list
Sourceval iter_vertex : (vertex -> unit) -> t -> unit
Sourceval fold_vertex : (vertex -> 'a -> 'a) -> t -> 'a -> 'a
Sourceval iter_edges : (vertex -> vertex -> unit) -> t -> unit
Sourceval fold_edges : (vertex -> vertex -> 'a -> 'a) -> t -> 'a -> 'a
Sourceval iter_edges_e : (edge -> unit) -> t -> unit
Sourceval fold_edges_e : (edge -> 'a -> 'a) -> t -> 'a -> 'a
Sourceval map_vertex : (vertex -> vertex) -> t -> t
Sourceval iter_succ : (vertex -> unit) -> t -> vertex -> unit
Sourceval iter_pred : (vertex -> unit) -> t -> vertex -> unit
Sourceval fold_succ : (vertex -> 'a -> 'a) -> t -> vertex -> 'a -> 'a
Sourceval fold_pred : (vertex -> 'a -> 'a) -> t -> vertex -> 'a -> 'a
Sourceval iter_succ_e : (edge -> unit) -> t -> vertex -> unit
Sourceval fold_succ_e : (edge -> 'a -> 'a) -> t -> vertex -> 'a -> 'a
Sourceval iter_pred_e : (edge -> unit) -> t -> vertex -> unit
Sourceval fold_pred_e : (edge -> 'a -> 'a) -> t -> vertex -> 'a -> 'a
Sourceval create : ?size:int -> unit -> t
Sourceval clear : t -> unit
Sourceval copy : t -> t
Sourceval add_vertex : t -> vertex -> unit
Sourceval remove_vertex : t -> vertex -> unit
Sourceval add_edge : t -> vertex -> vertex -> unit
Sourceval add_edge_e : t -> edge -> unit
Sourceval remove_edge : t -> vertex -> vertex -> unit
Sourceval remove_edge_e : t -> edge -> unit
Sourcetype g = t
Sourceval add_transitive_closure : ?reflexive:bool -> g -> g
Sourceval transitive_reduction : ?reflexive:bool -> g -> g
Sourceval replace_by_transitive_reduction : ?reflexive:bool -> g -> g
Sourceval mirror : g -> g
Sourceval complement : g -> g
Sourceval intersect : g -> g -> g
Sourceval union : g -> g -> g
Sourcemodule Topological : sig ... end
Sourcemodule Parallel : sig ... end
Sourcemodule Dot : sig ... end
Sourceval transitive_closure : ?reflexive:bool -> t -> unit
Sourceval build : V.t list -> E.t list -> t
Sourceval compare : t -> t -> int
Sourceval to_json : t OpamJson.encoder
Sourceval of_json : t OpamJson.decoder
Sourceval reduce : t -> t

Reduces a graph of atomic or concrete actions (only removals, installs and builds) by turning removal+install to reinstalls or up/down-grades, best for display. Dependency ordering won't be as accurate though, as there is no proper ordering of (reinstall a, reinstall b) if b depends on a. The resulting graph contains at most one action per package name.

There is no guarantee however that the resulting graph is acyclic.

Sourceval explicit : ?noop_remove:(package -> bool) -> sources_needed:(package -> bool) -> t -> t

Expand install actions, adding a build action preceding them. The argument noop_remove is a function that should return `true` for package where the `remove` action is known not to modify the filesystem (such as `conf-*` package). The argument sources_needed is a function that should return `true` for packages that require fetching sources (packages that do not require it are typically up-to-date pins or "in-place" builds).

Sourceval fold_descendants : (V.t -> 'a -> 'a) -> 'a -> t -> V.t -> 'a

Folds on all recursive successors of the given action, including itself, depth-first.

OCaml

Innovation. Community. Security.