Module: Ploy::Command

Defined in:
lib/ploy/command.rb,
lib/ploy/command/base.rb,
lib/ploy/command/help.rb,
lib/ploy/command/list.rb,
lib/ploy/command/bless.rb,
lib/ploy/command/build.rb,
lib/ploy/command/client.rb,
lib/ploy/command/oracle.rb,
lib/ploy/command/install.rb,
lib/ploy/command/publish.rb

Defined Under Namespace

Classes: Base, Bless, Build, Client, Help, Install, List, Oracle, OracleServer, Publish

Class Method Summary collapse

Class Method Details

.lookup(topic) ⇒ Object



12
13
14
15
16
17
18
19
20
21
22
23
24
25
# File 'lib/ploy/command.rb', line 12

def self.lookup(topic)
  lookup = {
    'install' => Ploy::Command::Install,
    'bless'   => Ploy::Command::Bless,
    'help'    => Ploy::Command::Help,
    'publish' => Ploy::Command::Publish,
    'oracle'  => Ploy::Command::Oracle,
    'client'  => Ploy::Command::Client,
    'build'   => Ploy::Command::Build,
    'list'    => Ploy::Command::List
  }
  mod = lookup[topic] || lookup['help']
  return mod.new
end