This file is indexed.

/usr/lib/ocaml/ocamlgraph/gmap.mli is in libocamlgraph-ocaml-dev 1.8.6-1build5.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 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
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
(**************************************************************************)
(*                                                                        *)
(*  Ocamlgraph: a generic graph library for OCaml                         *)
(*  Copyright (C) 2004-2010                                               *)
(*  Sylvain Conchon, Jean-Christophe Filliatre and Julien Signoles        *)
(*                                                                        *)
(*  This software is free software; you can redistribute it and/or        *)
(*  modify it under the terms of the GNU Library General Public           *)
(*  License version 2.1, with the special exception on linking            *)
(*  described in file LICENSE.                                            *)
(*                                                                        *)
(*  This software is distributed in the hope that it will be useful,      *)
(*  but WITHOUT ANY WARRANTY; without even the implied warranty of        *)
(*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.                  *)
(*                                                                        *)
(**************************************************************************)

(** Graph mapping. Map a graph to another one. *)

(** {2 Mapping of vertices} *)

(** Signature for the source graph. *)
module type V_SRC = sig
  type t
  module V : Sig.HASHABLE
  val fold_vertex : (V.t -> 'a -> 'a) -> t -> 'a -> 'a
end

(** Signature for the destination graph. *)
module type V_DST = sig
  type t
  type vertex
  val empty : unit -> t
  val add_vertex : t -> vertex -> t
end

(** Provide a mapping function from a mapping of vertices. *)
module Vertex(G_Src : V_SRC)(G_Dst : V_DST) : sig

  val map : (G_Src.V.t -> G_Dst.vertex) -> G_Src.t -> G_Dst.t
    (** [map f g] applies [f] to each vertex of [g] and so builds a new graph
	based on [g] *)

  val filter_map : (G_Src.V.t -> G_Dst.vertex option) -> G_Src.t -> G_Dst.t
    (** [filter_map f g] applies [f] to each vertex of [g] and so
        builds a new graph based on [g]; if [None] is returned by [f]
        the vertex is omitted in the new graph. *)

end

(** {2 Mapping of edges} *)

(** Signature for the source graph. *)
module type E_SRC = sig
  type t
  module E : Sig.ORDERED_TYPE
  val fold_edges_e : (E.t -> 'a -> 'a) -> t -> 'a -> 'a
end

(** Signature for the destination graph. *)
module type E_DST = sig
  type t
  type edge
  val empty : unit -> t
  val add_edge_e : t -> edge -> t
end

(** Provide a mapping function from a mapping of edges. *)
module Edge(G_Src: E_SRC)(G_Dst: E_DST) : sig

  val map : (G_Src.E.t -> G_Dst.edge) -> G_Src.t -> G_Dst.t
    (** [map f g] applies [f] to each edge of [g] and so builds a new graph
	based on [g] *)

  val filter_map : (G_Src.E.t -> G_Dst.edge option) -> G_Src.t -> G_Dst.t
    (** [filter_map f g] applies [f] to each edge of [g] and so builds
        a new graph based on [g]; if [None] is returned by [f] the
        edge is omitted in the new graph. *)

end