MCPcopy Create free account
hub / github.com/docker/cli / Set

Method Set

opts/duration.go:41–45  ·  view source on GitHub ↗

Set a new value on the option

(s string)

Source from the content-addressed store, hash-verified

39
40// Set a new value on the option
41func (d *DurationOpt) Set(s string) error {
42 v, err := time.ParseDuration(s)
43 d.value = &v
44 return err
45}
46
47// Type returns the type of this option, which will be displayed in `--help` output
48func (*DurationOpt) Type() string {

Callers 2

SetMethod · 0.45

Calls

no outgoing calls

Tested by 1