Schema
A node schema describes the fields a node type carries. Fields are added through
the fluent ISchema interface, and a finished schema is registered with
Graph.CreateNodeSchemaAsync — either
from a [Node]-annotated class or from a fluent definition. Field values use the
FieldType wire types below.
ISchema
public interface ISchema- Namespace
- Curiosity.Library
Methods
| Name | Description |
|---|---|
| Field | Adds a field named name of type type |
| ListField | Adds a List Field named name of type type |
| TableField | Adds a Table Field named name of type type |
| DictionaryField | Adds a Dictionary Field named name with value type type (key type is always string) |
ISchema ListField(string name, FieldType type)Adds a List Field named name of type type
ISchema TableField(string name, FieldType type)Adds a Table Field named name of type type
FieldType
public enum FieldTypeFor Fields (properties of nodes in the graph) these types are available.
- Namespace
- Curiosity.Library
Values
| Name | Description |
|---|---|
| SByte | Signed byte. |
| UInt32 | Unsigned integer with 32 bit. |
| UInt64 | unsigned integer with 64 bit. |
| Time | Format to process dates and time. It is possible to pass in Time or the C# formats DateTime and DateTimeOffset. |
| GeoPoint | See GeoPoint. Do not forget to resume indexing with ResumeAsync. |
| Language | See Language |
| UID128 | Unique identifier. See UID128 |
TimeFormat to process dates and time. It is possible to pass in Time or the C# formats DateTime and DateTimeOffset.
Applies to
Curiosity.Library — 2024.1 and later. Full type table and constraints in the Schema reference.