Class: A2::Subcommand::NodeMgmt::Get
- Inherits:
-
CmdParse::Command
- Object
- CmdParse::Command
- A2::Subcommand::NodeMgmt::Get
- Defined in:
- lib/a2/subcommands/node_mgmt.rb
Instance Method Summary collapse
- #execute(id) ⇒ Object
-
#initialize ⇒ Get
constructor
A new instance of Get.
Constructor Details
#initialize ⇒ Get
Returns a new instance of Get.
5 6 7 |
# File 'lib/a2/subcommands/node_mgmt.rb', line 5 def initialize super('get', takes_commands: false) end |
Instance Method Details
#execute(id) ⇒ Object
9 10 11 |
# File 'lib/a2/subcommands/node_mgmt.rb', line 9 def execute(id) puts JSON.pretty_generate(A2::Client.new(command_parser.data).get_managed_node(id)) end |