Class: Fog::Compute::ProfitBricks::IpBlocks
- Inherits:
-
Fog::Collection
- Object
- Fog::Collection
- Fog::Compute::ProfitBricks::IpBlocks
- Includes:
- Helpers::ProfitBricks::DataHelper
- Defined in:
- lib/fog/profitbricks/models/compute/ip_blocks.rb
Instance Method Summary collapse
Methods included from Helpers::ProfitBricks::DataHelper
Instance Method Details
#all ⇒ Object
11 12 13 14 15 |
# File 'lib/fog/profitbricks/models/compute/ip_blocks.rb', line 11 def all result = service.get_all_ip_blocks load(result.body['items'].each { |ip_block| flatten(ip_block) }) end |
#get(ip_block_id) ⇒ Object
17 18 19 20 21 |
# File 'lib/fog/profitbricks/models/compute/ip_blocks.rb', line 17 def get(ip_block_id) ip_block = service.get_ip_block(ip_block_id).body new(flatten(ip_block)) end |