Class: DeltacloudVM::Client::Helpers::Property::Fixed

Inherits:
Property
  • Object
show all
Defined in:
lib/deltacloud_vm/client/helpers/property_helper.rb

Instance Attribute Summary collapse

Attributes inherited from Property

#default, #name, #unit

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Property

#kind

Constructor Details

#initialize(name, unit, value) ⇒ Fixed

Returns a new instance of Fixed.



89
90
91
92
# File 'lib/deltacloud_vm/client/helpers/property_helper.rb', line 89

def initialize(name, unit, value)
  @value = value
  super(name, unit, @value)
end

Instance Attribute Details

#valueObject (readonly)

Returns the value of attribute value.



87
88
89
# File 'lib/deltacloud_vm/client/helpers/property_helper.rb', line 87

def value
  @value
end

Class Method Details

.parse(body) ⇒ Object



94
95
96
97
# File 'lib/deltacloud_vm/client/helpers/property_helper.rb', line 94

def self.parse(body)
  base = super
  new(base.name, base.unit, body['value'])
end