package mopsa

  1. Overview
  2. Docs
Legend:
Library
Module
Module type
Parameter
Class
Class type
type key

Keys of the map

type value

Values of the map

module KeySet : Mopsa_utils.SetExtSig.S with type elt = key

Set of keys

Set of values

type t

Type of inversible maps

val bottom : t

⊥ element

val top : t

⊤ element

val is_bottom : t -> bool

is_bottom a checks whether a is ⊥

val print : Core.All.Print.printer -> t -> unit

Pretty printer.

val empty : t

Singleton of empty map

val subset : t -> t -> bool

Inclusion test.

val join : t -> t -> t

Join two sets of partial maps.

val meet : t -> t -> t

Intersect to sets of partial maps.

val widen : 'a Core.All.ctx -> t -> t -> t

Widening operator

find k a find the set of values attached to key k in a. Raise Not_found of the key is not found.

val find_inverse : value -> t -> KeySet.t Mopsa_utils.Top.with_top

find_inverse finds the set of keys attached to value v in a.

val remove : key -> t -> t

remove k a removes all bindings (k,-) in a

val remove_inverse : value -> t -> t

remove_inverse v a remove all bindings (-,v) in a

val filter : (key -> ValueSet.t Mopsa_utils.Top.with_top -> bool) -> t -> t

filter f a keeps all bindings (k,vs) in a such that f k vs is true

val filter_inverse : (value -> KeySet.t -> bool) -> t -> t

filter_inverse f a keeps all inverse bindings (v,ks) in a such that f v ks is true

set k vs a adds the binding (k,vs) to a. Previous bindings are overwritten.

val add_inverse : value -> KeySet.t -> t -> t

add_inverse v ks a adds the binding (k,{v} ∪ find k a) to a, where kks.

val rename : key -> key -> t -> t

rename k k' a renames key k to k' in a

val rename_inverse : value -> value -> t -> t

rename k k' a renames value v to v' in a

val singleton : key -> value -> t

singleton k v createw a map with the singleton binding (k,{v})

val mem : key -> t -> bool

mem k a check whether a binding (k,-) exists in a

val mem_inverse : value -> t -> bool

mem v a check whether a binding (_,v) exists in a

val fold : (key -> ValueSet.t Mopsa_utils.Top.with_top -> 'a -> 'a) -> t -> 'a -> 'a

fold f a init folds function f over elements (k,vs) in a

map f a replace bindings (k,vs) in a with (k,f vs)

OCaml

Innovation. Community. Security.