Class: DNApi::Monitoring
- Defined in:
- lib/dnapi/monitoring.rb
Constant Summary collapse
- Monit =
new(:name => "monit", :label => "Monit")
- God =
new(:name => "god", :label => "god")
Instance Attribute Summary collapse
-
#label ⇒ Object
Returns the value of attribute label.
-
#name ⇒ Object
Returns the value of attribute name.
Attributes inherited from Struct
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from Struct
#==, _many, #_many, #_many_values, _ones, #_ones, #_ones_values, _umembers, belongs_to, from, #initialize, #inspect, many, map, one, #to_hash, #umember_inspect, unserialized_member
Methods included from Test::Ext
#default_fauxture_name, #fixture, #generate, #generate_attributes, #pick
Constructor Details
This class inherits a constructor from DNApi::Struct
Instance Attribute Details
#label ⇒ Object
Returns the value of attribute label
2 3 4 |
# File 'lib/dnapi/monitoring.rb', line 2 def label @label end |
#name ⇒ Object
Returns the value of attribute name
2 3 4 |
# File 'lib/dnapi/monitoring.rb', line 2 def name @name end |
Class Method Details
.get(name) ⇒ Object
10 11 12 |
# File 'lib/dnapi/monitoring.rb', line 10 def self.get(name) all.detect { |m| m.name == name } end |
Instance Method Details
#god? ⇒ Boolean
18 19 20 |
# File 'lib/dnapi/monitoring.rb', line 18 def god? name == "god" end |
#monit? ⇒ Boolean
14 15 16 |
# File 'lib/dnapi/monitoring.rb', line 14 def monit? name == "monit" end |