You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 line
476 B

  1. package maintnotifications
  2. // State represents the current state of a maintenance operation
  3. type State int
  4. const (
  5. // StateIdle indicates no upgrade is in progress
  6. StateIdle State = iota
  7. // StateHandoff indicates a connection handoff is in progress
  8. StateMoving
  9. )
  10. // String returns a string representation of the state.
  11. func (s State) String() string {
  12. switch s {
  13. case StateIdle:
  14. return "idle"
  15. case StateMoving:
  16. return "moving"
  17. default:
  18. return "unknown"
  19. }
  20. }