Class: Mccloud::Command::IpCommand
- Defined in:
- lib/mccloud/command/ip.rb
Instance Attribute Summary
Attributes inherited from GroupBase
Instance Method Summary collapse
- #associate(selection = nil) ⇒ Object
-
#list(selection = nil) ⇒ Object
method_options :test => :boolean.
Methods inherited from GroupBase
Methods included from Helpers
Constructor Details
This class inherits a constructor from Mccloud::Command::GroupBase
Instance Method Details
#associate(selection = nil) ⇒ Object
7 8 9 10 11 12 13 14 15 16 |
# File 'lib/mccloud/command/ip.rb', line 7 def associate(selection=nil) env.load! env.config.providers.each do |name,provider| env.logger.debug("Asking provider #{name} to associate to #{selection}") provider.on_selected_components("ip",selection) do |id,ip| ip.associate() end end end |
#list(selection = nil) ⇒ Object
method_options :test => :boolean
20 21 22 23 24 25 26 27 |
# File 'lib/mccloud/command/ip.rb', line 20 def list(selection=nil) env.load! env.config.providers.each do |name,provider| env.logger.debug("Asking provider #{name} to list ip #{selection}") provider.ip_list(selection,) end end |