Sha256: 52ef9b72d65ead75ee200840ca12cfdbc5268d066190fd70f68778dda4b2dd16
Contents?: true
Size: 713 Bytes
Versions: 6
Compression:
Stored size: 713 Bytes
Contents
require File.expand_path("../ip_address", __FILE__) module Fog module Compute class Ecloud class IpAddresses < Fog::Ecloud::Collection identity :href model Fog::Compute::Ecloud::IpAddress def all data = service.get_network(href).body data = if data[:IpAddresses] data[:IpAddresses][:IpAddress] else data end data = data.nil? ? [] : data load(data) end def get(uri) if data = service.get_ip_address(uri) new(data.body) end rescue Fog::Errors::NotFound nil end end end end end
Version data entries
6 entries across 6 versions & 2 rubygems