MCPcopy
hub / github.com/spf13/pflag / StringToStringVarP

Function StringToStringVarP

string_to_string.go:138–140  ·  view source on GitHub ↗

StringToStringVarP is like StringToStringVar, but accepts a shorthand letter that can be used after a single dash.

(p *map[string]string, name, shorthand string, value map[string]string, usage string)

Source from the content-addressed store, hash-verified

136
137// StringToStringVarP is like StringToStringVar, but accepts a shorthand letter that can be used after a single dash.
138func StringToStringVarP(p *map[string]string, name, shorthand string, value map[string]string, usage string) {
139 CommandLine.VarP(newStringToStringValue(value, p), name, shorthand, usage)
140}
141
142// StringToString defines a string flag with specified name, default value, and usage string.
143// The return value is the address of a map[string]string variable that stores the value of the flag.

Callers

nothing calls this directly

Calls 2

newStringToStringValueFunction · 0.85
VarPMethod · 0.80

Tested by

no test coverage detected