Schema Objects
class Schema(GraiBaseModel)
Class definition of Schema
Attributes:
entity
- A Grai object
to_model
@classmethod
def to_model(cls, item: Dict, version: Literal["v1"],
typing_type: Literal["Node", "Edge"]) -> GraiType
Convert an item spec to a Grai object
Arguments:
item
- An item spec to be converted to a Grai objectversion
- which version of the schema to usetyping_type
- The type of the object e.g. Node, Edge, etc.
Returns:
The Grai object