2015-04-25 20:54:17 +08:00
|
|
|
package main
|
|
|
|
|
|
|
|
import "time"
|
|
|
|
|
2015-05-01 19:37:28 +08:00
|
|
|
// UIData represents data to be passed to UI.
|
|
|
|
type UIData struct {
|
2015-05-02 01:12:23 +08:00
|
|
|
Services []*Service
|
2015-05-01 23:48:34 +08:00
|
|
|
Vars []VarName
|
2015-04-25 20:54:17 +08:00
|
|
|
LastTimestamp time.Time
|
|
|
|
}
|
|
|
|
|
2015-05-01 21:49:19 +08:00
|
|
|
// NewUIData inits and return new data object.
|
2015-05-01 23:48:34 +08:00
|
|
|
func NewUIData(vars []VarName) *UIData {
|
2015-05-01 21:49:19 +08:00
|
|
|
return &UIData{
|
|
|
|
Vars: vars,
|
|
|
|
}
|
2015-04-25 20:54:17 +08:00
|
|
|
}
|