2
* Graph: generic graph library
4
* Sylvain Conchon, Jean-Christophe Filliatre and Julien Signoles
6
* This software is free software; you can redistribute it and/or
7
* modify it under the terms of the GNU Library General Public
8
* License version 2, as published by the Free Software Foundation.
10
* This software is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
14
* See the GNU Library General Public License version 2 for more details
15
* (enclosed in the file LGPL).
18
(* $Id: gmap.ml,v 1.1 2004/10/20 09:59:56 signoles Exp $ *)
23
module V : Sig.HASHABLE
24
val fold_vertex : (V.t -> 'a -> 'a) -> t -> 'a -> 'a
30
val add_vertex : t -> vertex -> t
34
module H = Hashtbl.Make(G_Init.V)
36
let vertices = H.create 97
38
let convert_vertex f x =
49
(fun x g -> G_Dest.add_vertex g (convert_vertex f x))
57
module E : Sig.HASHABLE
58
val fold_edges_e : (E.t -> 'a -> 'a) -> t -> 'a -> 'a
64
val add_edge_e : t -> edge -> t
67
(struct include G_Init module V = E let fold_vertex = fold_edges_e end)
68
(struct include G_Dest type vertex = edge let add_vertex = add_edge_e end)