X-Git-Url: http://git.nguyen.vg/gitweb/?p=tatoo.git;a=blobdiff_plain;f=src%2Futils%2Fcache.mli;fp=src%2Futils%2Fcache.mli;h=dba99172674cd0c2ea53d537ac33a66e0f3a4d60;hp=0000000000000000000000000000000000000000;hb=748057239bad98bebc0f38403f05c1feb3712e82;hpb=0e6ff0ee8b034d096106b907a9d77831024a5d6e diff --git a/src/utils/cache.mli b/src/utils/cache.mli new file mode 100644 index 0000000..dba9917 --- /dev/null +++ b/src/utils/cache.mli @@ -0,0 +1,71 @@ +(***********************************************************************) +(* *) +(* TAToo *) +(* *) +(* Kim Nguyen, LRI UMR8623 *) +(* Université Paris-Sud & CNRS *) +(* *) +(* Copyright 2010-2013 Université Paris-Sud and Centre National de la *) +(* Recherche Scientifique. All rights reserved. This file is *) +(* distributed under the terms of the GNU Lesser General Public *) +(* License, with the special exception on linking described in file *) +(* ../LICENSE. *) +(* *) +(***********************************************************************) + +(* + Time-stamp: +*) + +(** N-dimentional caches *) + +module N1 : +sig + + type 'a t + val create : int -> 'a -> 'a t + val find : 'a t -> int -> 'a + val add : 'a t -> int -> 'a -> unit + val dummy : 'a t -> 'a + val iteri : (int -> 'a -> bool -> unit) -> 'a t -> unit +end + +module N2: +sig + type 'a t + val create : int -> 'a -> 'a t + val find : 'a t -> int -> int -> 'a + val add : 'a t -> int -> int -> 'a -> unit + val dummy : 'a t -> 'a + val iteri : (int -> int -> 'a -> bool -> unit) -> 'a t -> unit +end + +module N3 : + sig + type 'a t + val create : int -> 'a -> 'a t + val find : 'a t -> int -> int -> int -> 'a + val add : 'a t -> int -> int -> int -> 'a -> unit + val dummy : 'a t -> 'a + val iteri : (int -> int -> int -> 'a -> bool -> unit) -> 'a t -> unit + end + +module N4 : + sig + type 'a t + val create : int -> 'a -> 'a t + val find : 'a t -> int -> int -> int -> int -> 'a + val add : 'a t -> int -> int -> int -> int -> 'a -> unit + val dummy : 'a t -> 'a + val iteri : (int -> int -> int -> int -> 'a -> bool -> unit) -> 'a t -> unit + end + +module N5 : + sig + type 'a t + val create : int -> 'a -> 'a t + val find : 'a t -> int -> int -> int -> int -> int -> 'a + val add : 'a t -> int -> int -> int -> int -> int -> 'a -> unit + val dummy : 'a t -> 'a + val iteri : (int -> int -> int -> int -> int -> 'a -> bool -> unit) -> 'a t -> unit + end