Skip to main content
Version: Next

SchemaImpl

age-schema-client v0.5.0


age-schema-client / SchemaImpl

Class: SchemaImpl

Defined in: src/schema/schema.ts:61

Schema implementation that wraps a SchemaDefinition

Implements

Constructors

Constructor

new SchemaImpl(schemaDefinition): SchemaImpl;

Defined in: src/schema/schema.ts:69

Create a new SchemaImpl

Parameters

ParameterTypeDescription
schemaDefinitionSchemaDefinitionSchema definition

Returns

SchemaImpl

Methods

getVertexSchema()

getVertexSchema(vertexType): VertexLabel;

Defined in: src/schema/schema.ts:79

Get the vertex schema for a specific vertex type

Parameters

ParameterTypeDescription
vertexTypestringThe vertex type to get the schema for

Returns

VertexLabel

The vertex schema or undefined if not found

Implementation of

Schema.getVertexSchema


getEdgeSchema()

getEdgeSchema(edgeType): EdgeLabel;

Defined in: src/schema/schema.ts:89

Get the edge schema for a specific edge type

Parameters

ParameterTypeDescription
edgeTypestringThe edge type to get the schema for

Returns

EdgeLabel

The edge schema or undefined if not found

Implementation of

Schema.getEdgeSchema


getVertexTypes()

getVertexTypes(): string[];

Defined in: src/schema/schema.ts:98

Get all vertex types defined in the schema

Returns

string[]

Array of vertex type names

Implementation of

Schema.getVertexTypes


getEdgeTypes()

getEdgeTypes(): string[];

Defined in: src/schema/schema.ts:107

Get all edge types defined in the schema

Returns

string[]

Array of edge type names

Implementation of

Schema.getEdgeTypes


getSchemaDefinition()

getSchemaDefinition(): SchemaDefinition;

Defined in: src/schema/schema.ts:116

Get the schema definition

Returns

SchemaDefinition

The schema definition

Implementation of

Schema.getSchemaDefinition