Module Simantics/GUID
This module is undocumented. This is a list of its definitions.
claimGUID :: Resource -> <WriteGraph,Proc> ()
Gives the resource a new random GUID identifier if it does not have one yet.
A resource that already has an identifier is left alone, so its GUID stays
stable. Requires a write transaction.
guidBinding :: Binding a
The databoard binding of GUID values, needed by the value functions that
take a binding explicitly. Its type is left open, so it type checks
wherever a binding is expected; only use it to read and write GUID values.
guidIndexString :: GUID -> String
The GUID written as text: the two halves as unsigned hexadecimal separated
by an underscore. This is the form the GUID is indexed under, so it is what
a search by identifier matches against. show gives the same string.
guidOf :: Resource -> <ReadGraph> GUID
The GUID identifier of the resource. Fails if the resource has no
L0.identifier property. Requires a read transaction.
possibleGUIDOf :: Resource -> <ReadGraph> Maybe GUID
The GUID identifier of the resource, or Nothing if it has no
L0.identifier property. Requires a read transaction.
randomGUID :: <Proc> GUID
A new random GUID. Two calls never return the same value in practice.
|