mirror of
https://github.com/Theodor-Springmann-Stiftung/kgpz_web.git
synced 2025-10-29 17:15:31 +00:00
Better structure of files; introduced XML models
This commit is contained in:
47
xmlmodels/references.go
Normal file
47
xmlmodels/references.go
Normal file
@@ -0,0 +1,47 @@
|
||||
package xmlmodels
|
||||
|
||||
import "encoding/xml"
|
||||
|
||||
type Reference struct {
|
||||
Ref string `xml:"ref,attr"`
|
||||
Category string `xml:"kat,attr"`
|
||||
Unsicher bool `xml:"unsicher,attr"`
|
||||
Value
|
||||
}
|
||||
|
||||
type AgentRef struct {
|
||||
XMLName xml.Name `xml:"akteur"`
|
||||
Reference
|
||||
}
|
||||
|
||||
type IssueRef struct {
|
||||
XMLName xml.Name `xml:"stueck"`
|
||||
Nr int `xml:"nr,attr"`
|
||||
Von int `xml:"von,attr"`
|
||||
Bis int `xml:"bis,attr"`
|
||||
Beilage int `xml:"beilage,attr"`
|
||||
DateAttributes
|
||||
Reference // Nicht im Schema
|
||||
}
|
||||
|
||||
type PlaceRef struct {
|
||||
XMLName xml.Name `xml:"ort"`
|
||||
Reference
|
||||
}
|
||||
|
||||
type CategoryRef struct {
|
||||
XMLName xml.Name `xml:"kategorie"`
|
||||
Reference
|
||||
}
|
||||
|
||||
type WorkRef struct {
|
||||
XMLName xml.Name `xml:"werk"`
|
||||
Page string `xml:"s,attr"`
|
||||
Reference
|
||||
}
|
||||
|
||||
type PieceRef struct {
|
||||
XMLName xml.Name `xml:"beitrag"`
|
||||
Page string `xml:"s,attr"`
|
||||
Reference
|
||||
}
|
||||
Reference in New Issue
Block a user