Sha256: ba19ad802cdd3b02c294242be28586a5fd3a41375068cf681c881929c76a1f7e

Contents?: true

Size: 606 Bytes

Versions: 28

Compression:

Stored size: 606 Bytes

Contents

require 'fog/core/collection'
require 'fog/vsphere/models/compute/folder'

module Fog
  module Compute
    class Vsphere
      class Folders < Fog::Collection
        model Fog::Compute::Vsphere::Folder
        attr_accessor :datacenter, :type, :path

        def all(filters = { })
          requires :datacenter
          requires :type
          load service.list_folders(filters.merge(:datacenter => datacenter, :type => type, :path => path))
        end

        def get(id)
          requires :datacenter
          new service.get_folder(id, datacenter, type)
        end
      end
    end
  end
end

Version data entries

28 entries across 28 versions & 4 rubygems

Version Path
fog-1.36.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.35.0 lib/fog/vsphere/models/compute/folders.rb
fog-2.0.0.pre.0 lib/fog/vsphere/models/compute/folders.rb
vagrant-cloudstack-1.2.0 vendor/bundle/gems/fog-1.32.0/lib/fog/vsphere/models/compute/folders.rb
fog-1.34.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.33.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.32.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.31.0 lib/fog/vsphere/models/compute/folders.rb
vagrant-cloudstack-1.1.0 vendor/bundle/gems/fog-1.22.1/lib/fog/vsphere/models/compute/folders.rb
fog-1.30.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.29.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.28.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.27.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.26.0 lib/fog/vsphere/models/compute/folders.rb
fog-1.25.0 lib/fog/vsphere/models/compute/folders.rb
nsidc-fog-1.24.1 lib/fog/vsphere/models/compute/folders.rb
fog-1.24.0 lib/fog/vsphere/models/compute/folders.rb
ns-fog-1.22.11 lib/fog/vsphere/models/compute/folders.rb
ns-fog-1.22.10 lib/fog/vsphere/models/compute/folders.rb
ns-fog-1.22.9 lib/fog/vsphere/models/compute/folders.rb