Sha256: 68b388617700780642f88f6221990bab5d30aac83ef53441b86094a1775e024e

Contents?: true

Size: 587 Bytes

Versions: 67

Compression:

Stored size: 587 Bytes

Contents

require 'fog/core/collection'
require 'fog/xenserver/models/compute/pif'

module Fog
  module Compute
    class XenServer

      class Pifs < Fog::Collection

        model Fog::Compute::XenServer::PIF

        def initialize(attributes)
          super
        end

        def all(options = {})
          data = service.get_records 'PIF'
          load(data)
        end

        def get( ref )
          if ref && obj = service.get_record( ref, 'PIF' )
            new(obj)
          end
        rescue Fog::XenServer::NotFound
          nil
        end

      end

    end
  end
end

Version data entries

67 entries across 67 versions & 7 rubygems

Version Path
fog-1.10.1 lib/fog/xenserver/models/compute/pifs.rb
fog-test-me-1.10.0 lib/fog/xenserver/models/compute/pifs.rb
fog-1.10.0 lib/fog/xenserver/models/compute/pifs.rb
fog-1.9.0 lib/fog/xenserver/models/compute/pifs.rb
fog-maestrodev-1.8.0.20130114204828 lib/fog/xenserver/models/compute/pifs.rb
fog-maestrodev-1.8.0.20130111070250 lib/fog/xenserver/models/compute/pifs.rb
fog-maestrodev-1.8.0.20130109172219 lib/fog/xenserver/models/compute/pifs.rb