aboutsummaryrefslogtreecommitdiffstats
path: root/lib/kernel/SubstantialRelation.mli
diff options
context:
space:
mode:
authorMarcos Magueta <maguetamarcos@gmail.com>2026-09-09 22:35:09 -0300
committerMarcos Magueta <maguetamarcos@gmail.com>2026-09-11 01:10:28 -0300
commit152f817f8dc622aec7936ace7c16ce645aaed159 (patch)
tree045d24750c7960983b366ea13afc464d518b7a3f /lib/kernel/SubstantialRelation.mli
parent8baa58d7683b092d9e27e35d46a6b9ecb61fa4ab (diff)
downloadRNT-152f817f8dc622aec7936ace7c16ce645aaed159.tar.gz
RNT-152f817f8dc622aec7936ace7c16ce645aaed159.zip
substantial relation and schematics
Diffstat (limited to '')
-rw-r--r--lib/kernel/SubstantialRelation.mli17
1 files changed, 16 insertions, 1 deletions
diff --git a/lib/kernel/SubstantialRelation.mli b/lib/kernel/SubstantialRelation.mli
index 9e61411..866c3a0 100644
--- a/lib/kernel/SubstantialRelation.mli
+++ b/lib/kernel/SubstantialRelation.mli
@@ -1,4 +1,7 @@
-module Make (S : Abstract.Storage.STORAGE) : sig
+module Make (S : Abstract.Storage.STORAGE) (Schematics : sig
+ include Protocols.Schematics.S
+ val of_blob : Concepts.Blob.t -> (Schema.t, Concepts.Condition.condition) result
+end) : sig
type t
val encode : t -> Concepts.Blob.t
@@ -46,4 +49,16 @@ module Make (S : Abstract.Storage.STORAGE) : sig
val contains_tuple :
S.transaction -> t -> Concepts.Blob.t -> (bool, Concepts.Condition.condition) result
+
+ (** decodes the heading at [heading relation] -- the body of
+ [Schematics.schema] for this kind of relation. *)
+ val heading_value : S.transaction -> t -> (Schematics.Schema.t, Concepts.Condition.condition) result
+
+ (** a handle carrying [Protocols.Cursor] over every tuple currently
+ asserted, decoded via [Concepts.Tuple.Representation.of_blob] --
+ the body of [Protocols.Relation.enumerate] for this kind of
+ relation. Opens its own storage transaction, held for the
+ cursor's whole lifetime rather than just this call -- see
+ [Kernel.Generator] and docs/design/evaluator.md, "Shape". *)
+ val enumerate : S.connection -> t -> (Protocols.Handle.t, Concepts.Condition.condition) result
end