better indexing

This commit is contained in:
Martino Ferrari
2026-01-22 01:53:45 +01:00
parent 4a624aa929
commit f111bf1aaa
5 changed files with 291 additions and 69 deletions

View File

@@ -16,8 +16,9 @@ type Schema struct {
}
type ClassDefinition struct {
Fields []FieldDefinition `json:"fields"`
Ordered bool `json:"ordered"`
Fields []FieldDefinition `json:"fields"`
Ordered bool `json:"ordered"`
Direction string `json:"direction"`
}
type FieldDefinition struct {
@@ -96,6 +97,9 @@ func (s *Schema) Merge(other *Schema) {
if classDef.Ordered {
existingClass.Ordered = true
}
if classDef.Direction != "" {
existingClass.Direction = classDef.Direction
}
s.Classes[className] = existingClass
} else {
s.Classes[className] = classDef