Legend:
Library
Module
Module type
Parameter
Class
Class type
Library
Module
Module type
Parameter
Class
Class type
type t =
| Set of Key_in_collection.t * string
| Unset of Key_in_collection.t
| Sequence of t list
| Check of Key_in_collection.t * string option
An action is a transaction that (attempts) to modify the database.
*)val set : ?collection:string -> key:string -> string -> t
Create a “set” action: set ~key v
will add or set the value v
for the key key
, optionally in the collection collection
.
val contains : ?collection:string -> key:string -> string -> t
An action that checks that the key
is set in the DB and has the given value.
val is_not_set : ?collection:string -> string -> t
An action that checks that the key
is not set in the DB.
val unset : ?collection:string -> string -> t
An actions that removes a value from the DB.
val to_string : t -> string
Convert the action to a display friendly string (the implementation is quite naive and not tail-recursive, hence avoid displaying huge transaction).