Class: Fog::Vsphere::Compute::Customfields
- Inherits:
-
Collection
- Object
- Collection
- Fog::Vsphere::Compute::Customfields
- Defined in:
- lib/fog/vsphere/models/compute/customfields.rb
Instance Attribute Summary collapse
-
#vm ⇒ Object
Returns the value of attribute vm.
Instance Method Summary collapse
Instance Attribute Details
#vm ⇒ Object
Returns the value of attribute vm.
7 8 9 |
# File 'lib/fog/vsphere/models/compute/customfields.rb', line 7 def vm @vm end |
Instance Method Details
#all(_filters = {}) ⇒ Object
9 10 11 |
# File 'lib/fog/vsphere/models/compute/customfields.rb', line 9 def all(_filters = {}) load service.list_customfields end |
#get(key) ⇒ Object
13 14 15 16 17 |
# File 'lib/fog/vsphere/models/compute/customfields.rb', line 13 def get(key) load(service.list_customfields).find do |cv| cv.key == (key.is_a? String ? key.to_i : key) end end |