kon/client/state/state.go
2024-04-01 21:09:41 +02:00

29 lines
337 B
Go

package state
import (
"sync"
"time"
)
type StateStruct struct {
Machines map[string]Machine
Mutex sync.RWMutex
}
type Machine struct {
State int
JobStart time.Time
JobEnd time.Time
Message string
}
const (
Working = iota
Completed
Error
)
var State StateStruct = StateStruct{
Machines: map[string]Machine{},
}