package logtk

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type ('id, 'v, 'e) t

Mutable graph

val create : ?eq:('id -> 'id -> bool) -> ?hash:('id -> int) -> unit -> ('id, 'v, 'e) t * ('id, 'v, 'e) graph

Create a new graph from the given equality and hash function, plus a view of it as an abstract graph

val add_vertex : ('id, 'v, 'e) t -> 'id -> 'v -> unit

Add a vertex to the graph

val add_edge : ('id, 'v, 'e) t -> 'id -> 'e -> 'id -> unit

Add an edge; the two vertices must already exist