github.com/loggregator/cli@v6.33.1-0.20180224010324-82334f081791+incompatible/cf/commandregistry/fakecommand/fake_command2.go (about) 1 package fakecommand 2 3 import ( 4 "code.cloudfoundry.org/cli/cf/commandregistry" 5 "code.cloudfoundry.org/cli/cf/flags" 6 "code.cloudfoundry.org/cli/cf/requirements" 7 ) 8 9 type FakeCommand2 struct { 10 Data string 11 } 12 13 func (cmd FakeCommand2) MetaData() commandregistry.CommandMetadata { 14 return commandregistry.CommandMetadata{ 15 Name: "fake-command2", 16 ShortName: "fc2", 17 Description: "Description for fake-command2", 18 Usage: []string{ 19 "Usage of fake-command2", 20 }, 21 } 22 } 23 24 func (cmd FakeCommand2) Requirements(_ requirements.Factory, _ flags.FlagContext) ([]requirements.Requirement, error) { 25 return []requirements.Requirement{}, nil 26 } 27 28 func (cmd FakeCommand2) SetDependency(deps commandregistry.Dependency, _ bool) commandregistry.Command { 29 return cmd 30 } 31 32 func (cmd FakeCommand2) Execute(c flags.FlagContext) error { 33 return nil 34 }