Class: Fog::Compute::Google::Flavors
- Inherits:
-
Fog::Collection
- Object
- Fog::Collection
- Fog::Compute::Google::Flavors
- Defined in:
- lib/fog/google/models/compute/flavors.rb
Instance Method Summary collapse
Instance Method Details
#all(filters = {}) ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 |
# File 'lib/fog/google/models/compute/flavors.rb', line 10 def all(filters = {}) if filters[:zone] data = service.list_machine_types(filters[:zone]).body["items"] else data = [] service.list_aggregated_machine_types.body['items'].each_value do |zone| data.concat(zone['machineTypes']) if zone['machineTypes'] end end load(data) end |