View Source surreal_entity (surreal v2.1.0)
Link to this section Summary
Types
An identifier that serves as a unique reference for entities within a database, encompassing both database tables and record identifiers.
A tuple representing a database record's location using the table name and a unique identifier.
A type that can represent either an entity identifier or a record specification.
Functions
Converts given
thing()
to entity_identifier()
.Link to this section Types
-type entity_identifier() :: iodata().
An identifier that serves as a unique reference for entities within a database, encompassing both database tables and record identifiers.
- "employees"
: Represents the table containing employee records.
"employees:meppu"
: Identifies a specific employee record.
-type record_specification() :: {Table :: iodata(), Id :: iodata()}.
A tuple representing a database record's location using the table name and a unique identifier.
-{"employees", "meppu"}
: Refers to an employee record in the employees
table.
-type thing() :: entity_identifier() | record_specification().
Link to this section Functions
-spec convert(Thing :: thing()) -> entity_identifier().
thing()
to entity_identifier()
.