-
Notifications
You must be signed in to change notification settings - Fork 0
/
event.go
65 lines (58 loc) · 2.1 KB
/
event.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
package model
import "time"
//nolint:tagliatelle // client compatibility
type DbEvent struct {
ID int `json:"id"`
Name string `json:"name"`
Key string `json:"eventKey"`
Description string `json:"description"`
RecordStamp time.Time `json:"recordDate"`
Data EventData `json:"data"`
}
type DbEventExtra struct {
ID int `json:"id"`
EventID int `json:"eventId"`
Data ExtraInfo `json:"data"`
}
type EventData struct {
Info EventDataInfo `json:"info"`
Manifests Manifests `json:"manifests"`
ReplayInfo ReplayInfo `json:"replayInfo"`
}
type EventDataInfo struct {
TrackId int `json:"trackId"`
TrackDisplayName string `json:"trackDisplayName"`
TrackDisplayShortName string `json:"trackDisplayShortName"`
TrackConfigName string `json:"trackConfigName"`
TrackLength float64 `json:"trackLength"`
TrackPitSpeed float64 `json:"trackPitSpeed"`
Name string `json:"name"`
Description string `json:"description"`
EventTime string `json:"eventTime"`
RaceloggerVersion string `json:"raceloggerVersion"`
TeamRacing int `json:"teamRacing"` // 0: false
MultiClass bool `json:"multiClass"`
NumCarTypes int `json:"numCarTypes"`
NumCarClasses int `json:"numCarClasses"`
IrSessionId int `json:"irSessionId"`
Sectors []Sector `json:"sectors"`
Sessions []EventSession `json:"sessions"`
}
type EventSession struct {
Num int `json:"num"`
Name string `json:"name"`
}
type Manifests struct {
Car []string `json:"car"`
Pit []string `json:"pit"`
Message []string `json:"message"`
Session []string `json:"session"`
}
type ReplayInfo struct {
MinTimestamp float64 `json:"minTimestamp"`
MinSessionTime float64 `json:"minSessionTime"`
MaxSessionTime float64 `json:"maxSessionTime"`
}
type ExtraInfo struct {
Track TrackInfo `json:"track"`
}