X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Fng_library%2FnCicLibrary.mli;h=03b84439711b872d317aa295c04fd6880f7570f6;hb=f2771b346a41445df23adb6acccd7ee6b1578666;hp=e155aaf4a3526e043f8d07a2e9562f7ed01cc492;hpb=a18562238677261e3d0b590e046290a14fe62e74;p=helm.git diff --git a/helm/software/components/ng_library/nCicLibrary.mli b/helm/software/components/ng_library/nCicLibrary.mli index e155aaf4a..03b844397 100644 --- a/helm/software/components/ng_library/nCicLibrary.mli +++ b/helm/software/components/ng_library/nCicLibrary.mli @@ -13,6 +13,33 @@ exception LibraryOutOfSync of string Lazy.t +type automation_cache = NDiscriminationTree.DiscriminationTree.t +type unit_eq_cache = NCicParamod.state + +class type g_eq_status = + object + method eq_cache : unit_eq_cache + end + +class eq_status : + object('self) + inherit g_eq_status + method set_eq_cache: unit_eq_cache -> 'self + method set_eq_status: #g_eq_status -> 'self + end + +class type g_auto_status = + object + method auto_cache : automation_cache + end + +class auto_status : + object('self) + inherit g_auto_status + method set_auto_cache: automation_cache -> 'self + method set_auto_status: #g_auto_status -> 'self + end + type timestamp class type g_status = @@ -42,40 +69,41 @@ val clear_cache : unit -> unit val time_travel: #status -> unit val decompile: baseuri:NUri.uri -> unit -module type SerializerT = - sig - type status - type obj - val register: - string -> - ('a -> refresh_uri_in_universe:(NCic.universe -> NCic.universe) -> refresh_uri_in_term:(NCic.term -> NCic.term) -> status -> status) -> - ('a -> obj) - val serialize: baseuri:NUri.uri -> obj list -> unit - val require: baseuri:NUri.uri -> status -> status - end - val init: unit -> unit -module Serializer: - sig - include SerializerT with type status = status - val require: baseuri:NUri.uri -> (#status as 'status) -> 'status - end +type obj class type g_dumpable_status = object inherit g_status - method dump: Serializer.obj list + inherit g_auto_status + inherit g_eq_status + method dump: obj list end - + class dumpable_status : object ('self) inherit status + inherit auto_status + inherit eq_status inherit g_dumpable_status - method set_dump: Serializer.obj list -> 'self + method set_dump: obj list -> 'self method set_dumpable_status: #g_dumpable_status -> 'self end +type 'a register_type = + < run: 'status. + 'a -> refresh_uri_in_universe:(NCic.universe -> + NCic.universe) -> refresh_uri_in_term:(NCic.term -> NCic.term) -> + (#dumpable_status as 'status) -> 'status > + +module Serializer: + sig + val register: < run: 'a. string -> 'a register_type -> ('a -> obj) > + val serialize: baseuri:NUri.uri -> obj list -> unit + val require: baseuri:NUri.uri -> (#dumpable_status as 'status) -> 'status + end + (* CSC: only required during old-to-NG phase, to be deleted *) val refresh_uri: NUri.uri -> NUri.uri