Class: ZAWS::Command::Newrelic
- Inherits:
-
Thor
- Object
- Thor
- ZAWS::Command::Newrelic
- Defined in:
- lib/zaws/command/newrelic.rb
Instance Attribute Summary collapse
-
#newrelic ⇒ Object
Returns the value of attribute newrelic.
-
#out ⇒ Object
Returns the value of attribute out.
-
#print_exit_code ⇒ Object
Returns the value of attribute print_exit_code.
Instance Method Summary collapse
-
#initialize(*args) ⇒ Newrelic
constructor
A new instance of Newrelic.
- #view_servers ⇒ Object
Constructor Details
#initialize(*args) ⇒ Newrelic
Returns a new instance of Newrelic.
12 13 14 15 16 17 18 19 |
# File 'lib/zaws/command/newrelic.rb', line 12 def initialize(*args) super shellout=ZAWS::Helper::Shell.new newrelicapi = ZAWS::Newrelicapi.new(shellout) @newrelic = ZAWS::Controllers::Newrelic.new(shellout, newrelicapi) @out = $stdout @print_exit_code = false end |
Instance Attribute Details
#newrelic ⇒ Object
Returns the value of attribute newrelic.
8 9 10 |
# File 'lib/zaws/command/newrelic.rb', line 8 def newrelic @newrelic end |
#out ⇒ Object
Returns the value of attribute out.
9 10 11 |
# File 'lib/zaws/command/newrelic.rb', line 9 def out @out end |
#print_exit_code ⇒ Object
Returns the value of attribute print_exit_code.
10 11 12 |
# File 'lib/zaws/command/newrelic.rb', line 10 def print_exit_code @print_exit_code end |
Instance Method Details
#view_servers ⇒ Object
23 24 25 |
# File 'lib/zaws/command/newrelic.rb', line 23 def view_servers @newrelic.servers.view([:home], @out, ([:verbose] ? @out : nil)) end |