MCPcopy Create free account
hub / github.com/docker/compose / String

Method String

pkg/compose/plan.go:59–88  ·  view source on GitHub ↗

String returns the human-readable name of an OperationType.

()

Source from the content-addressed store, hash-verified

57
58// String returns the human-readable name of an OperationType.
59func (o OperationType) String() string {
60 switch o {
61 case OpCreateNetwork:
62 return "CreateNetwork"
63 case OpRemoveNetwork:
64 return "RemoveNetwork"
65 case OpDisconnectNetwork:
66 return "DisconnectNetwork"
67 case OpConnectNetwork:
68 return "ConnectNetwork"
69 case OpCreateVolume:
70 return "CreateVolume"
71 case OpRemoveVolume:
72 return "RemoveVolume"
73 case OpCreateContainer:
74 return "CreateContainer"
75 case OpStartContainer:
76 return "StartContainer"
77 case OpStopContainer:
78 return "StopContainer"
79 case OpRemoveContainer:
80 return "RemoveContainer"
81 case OpRenameContainer:
82 return "RenameContainer"
83 case OpRunProvider:
84 return "RunProvider"
85 default:
86 return fmt.Sprintf("Unknown(%d)", int(o))
87 }
88}
89
90// Operation describes a single atomic action to be performed by the executor.
91type Operation struct {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected