package fortop import ( "encoding/xml" "git.fuyu.moe/5GPowerQuality/parser/shared" ) // FortopFormat .. type FortopFormat struct { XMLName xml.Name `xml:"Trafo-Details"` Trafo struct { TrafoNummer int `xml:"trafonummer"` Meter []Meter `xml:"meter"` } `xml:"trafo"` } // Meter contains all data from one specific meter type Meter struct { MeterID string `xml:"meter-id"` StartDate shared.UnixTimestamp `xml:"startdate"` EndDate shared.UnixTimestamp `xml:"enddate"` Meetwaarde []Meetwaarde `xml:"meetwaarde"` } // Meetwaarde contains the data that is not pointless garbage type Meetwaarde struct { Naam string `xml:"naam"` Range []Range `xml:"range"` } // Range is a single set of data type Range struct { Date shared.UnixTimestamp `xml:"date"` Value float64 `xml:"value"` }