Better structure of files; introduced XML models

This commit is contained in:
Simon Martens
2025-01-01 17:00:26 +01:00
parent e46d540c01
commit 7539a2dca7
25 changed files with 297 additions and 348 deletions

18
xmlmodels/categories.go Normal file
View File

@@ -0,0 +1,18 @@
package xmlmodels
import (
"encoding/xml"
"fmt"
)
type Category struct {
XMLName xml.Name `xml:"kategorie"`
Names []string `xml:"name"`
SortName string `xml:"sortiername"`
Identifier
AnnotationNote
}
func (c Category) String() string {
return fmt.Sprintf("ID: %s\nNames: %v\nSortName: %s\nAnnotations: %v\nNotes: %v\n", c.ID, c.Names, c.SortName, c.Annotations, c.Notes)
}