MCPcopy
hub / github.com/cloudfoundry/cli / NewClient

Function NewClient

api/plugin/client.go:39–53  ·  view source on GitHub ↗

NewClient returns a new plugin Client.

(config Config)

Source from the content-addressed store, hash-verified

37
38// NewClient returns a new plugin Client.
39func NewClient(config Config) *Client {
40 userAgent := fmt.Sprintf("%s/%s (%s; %s %s)",
41 config.AppName,
42 config.AppVersion,
43 runtime.Version(),
44 runtime.GOARCH,
45 runtime.GOOS,
46 )
47 client := Client{
48 userAgent: userAgent,
49 connection: NewConnection(config.SkipSSLValidation, config.DialTimeout),
50 }
51
52 return &client
53}

Callers 2

NewClientFunction · 0.92
NewTestClientFunction · 0.70

Calls 2

VersionMethod · 0.80
NewConnectionFunction · 0.70

Tested by 1

NewTestClientFunction · 0.56