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

Method Requirements

cf/commands/plugin/plugins.go:40–52  ·  view source on GitHub ↗
(requirementsFactory requirements.Factory, fc flags.FlagContext)

Source from the content-addressed store, hash-verified

38}
39
40func (cmd *Plugins) Requirements(requirementsFactory requirements.Factory, fc flags.FlagContext) ([]requirements.Requirement, error) {
41 usageReq := requirements.NewUsageRequirement(commandregistry.CLICommandUsagePresenter(cmd),
42 T("No argument required"),
43 func() bool {
44 return len(fc.Args()) != 0
45 },
46 )
47
48 reqs := []requirements.Requirement{
49 usageReq,
50 }
51 return reqs, nil
52}
53
54func (cmd *Plugins) SetDependency(deps commandregistry.Dependency, pluginCall bool) commandregistry.Command {
55 cmd.ui = deps.UI

Callers

nothing calls this directly

Calls 3

NewUsageRequirementFunction · 0.92
CLICommandUsagePresenterFunction · 0.92
ArgsMethod · 0.65

Tested by

no test coverage detected