Sha256: e8bcb186f08446cd19d54b496f17b82f8d2937ae72fec1d974c7b30160cce16b

Contents?: true

Size: 538 Bytes

Versions: 11

Compression:

Stored size: 538 Bytes

Contents

require 'fog/vcloud/models/compute/vapp'

module Fog
  module Vcloud
    class Compute

      class Vapps < Collection

        model Fog::Vcloud::Compute::Vapp

        undef_method :create

        attribute :href

        def all
          load([connection.get_vdc(self.href).resource_entities].flatten.select { |re| re[:type] == "application/vnd.vmware.vcloud.vApp+xml" })
        end

        def get(uri)
          connection.get_vapp(uri)
        rescue Fog::Errors::NotFound
          nil
        end

      end
    end
  end
end

Version data entries

11 entries across 11 versions & 5 rubygems

Version Path
fog-1.5.0 lib/fog/vcloud/models/compute/vapps.rb
fog-1.4.0 lib/fog/vcloud/models/compute/vapps.rb
brightbox-cli-0.18.1 lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vapps.rb
michiels-fog-1.3.1 lib/fog/vcloud/models/compute/vapps.rb
ftl-0.2.0 vendor/bundle/gems/fog-1.3.1/lib/fog/vcloud/models/compute/vapps.rb
brightbox-cli-0.18.0 lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vapps.rb
fog-1.3.1 lib/fog/vcloud/models/compute/vapps.rb
fog-1.3.0 lib/fog/vcloud/models/compute/vapps.rb
brightbox-cli-0.17.5 lib/brightbox-cli/vendor/fog/lib/fog/vcloud/models/compute/vapps.rb
fog-1.2.0 lib/fog/vcloud/models/compute/vapps.rb
ktheory-fog-1.1.2 lib/fog/vcloud/models/compute/vapps.rb