Class: Hawkular::Inventory::Operation
- Inherits:
-
Object
- Object
- Hawkular::Inventory::Operation
- Defined in:
- lib/hawkular/inventory/entities.rb
Instance Attribute Summary collapse
-
#name ⇒ String
readonly
Name of the operation.
-
#params ⇒ Object
readonly
Returns the value of attribute params.
Instance Method Summary collapse
-
#initialize(op_hash) ⇒ Operation
constructor
A new instance of Operation.
Constructor Details
#initialize(op_hash) ⇒ Operation
Returns a new instance of Operation.
42 43 44 45 |
# File 'lib/hawkular/inventory/entities.rb', line 42 def initialize(op_hash) @name = op_hash['name'] @params = op_hash.key?('parameters') ? op_hash['parameters'] : {} end |
Instance Attribute Details
#name ⇒ String (readonly)
Returns Name of the operation.
39 40 41 |
# File 'lib/hawkular/inventory/entities.rb', line 39 def name @name end |
#params ⇒ Object (readonly)
Returns the value of attribute params.
40 41 42 |
# File 'lib/hawkular/inventory/entities.rb', line 40 def params @params end |