Files
docker-docs/state/state.go
Evan Hazlett 909e69baff initial work on aws for machine; huge thanks to @nathanleclaire for the
initial implementation

Signed-off-by: Evan Hazlett <ejhazlett@gmail.com>
2014-12-12 17:00:57 -05:00

34 lines
369 B
Go

package state
// State represents the state of a hosts
type State int
const (
None State = iota
Running
Paused
Saved
Stopped
Stopping
Starting
Error
)
var states = []string{
"",
"Running",
"Paused",
"Saved",
"Stopped",
"Stopping",
"Starting",
"Error",
}
func (s State) String() string {
if int(s) < len(states) {
return states[s]
}
return ""
}