Sha256: 485448a4a18e7bf7c75be33f486ca2e65692475247f96b6b1627cb93cfdbbab1
Contents?: true
Size: 774 Bytes
Versions: 5
Compression:
Stored size: 774 Bytes
Contents
require 'fog/core/collection' require 'fog/openstack/models/network/floating_ip' module Fog module Network class OpenStack class FloatingIps < Fog::Collection attribute :filters model Fog::Network::OpenStack::FloatingIp def initialize(attributes) self.filters ||= {} super end def all(filters_arg = filters) filters = filters_arg load(service.list_floating_ips(filters).body['floatingips']) end def get(floating_network_id) if floating_ip = service.get_floating_ip(floating_network_id).body['floatingip'] new(floating_ip) end rescue Fog::Network::OpenStack::NotFound nil end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems