MCPcopy Index your code
hub / github.com/docker/cli / WithAPIClient

Function WithAPIClient

cli/command/cli_options.go:88–93  ·  view source on GitHub ↗

WithAPIClient configures the cli to use the given API client.

(c client.APIClient)

Source from the content-addressed store, hash-verified

86
87// WithAPIClient configures the cli to use the given API client.
88func WithAPIClient(c client.APIClient) CLIOption {
89 return func(cli *DockerCli) error {
90 cli.client = c
91 return nil
92 }
93}
94
95// WithInitializeClient is passed to [DockerCli.Initialize] to initialize
96// an API Client for use by the CLI.

Calls

no outgoing calls

Used in the wild real call sites across dependent graphs

searching dependent graphs…