Sha256: 828ff6469a1ced59da7251c03ed63dd886948b861972ccca9bdb2be0cbdb0396

Contents?: true

Size: 938 Bytes

Versions: 16

Compression:

Stored size: 938 Bytes

Contents

module Fog
  module Compute
    class Vsphere
      class Cluster < Fog::Model
        identity :id

        attribute :name
        attribute :datacenter
        attribute :num_host
        attribute :num_cpu_cores
        attribute :overall_status
        attribute :full_path

        def resource_pools(filters = { })
          self.attributes[:resource_pools] ||= id.nil? ? [] : service.resource_pools({
                                                                                          :service => service,
                                                                                          :cluster    => name,
                                                                                          :datacenter => datacenter
                                                                                        }.merge(filters))
        end

        def to_s
          name
        end
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 3 rubygems

Version Path
fog-vsphere-0.3.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.36.0 lib/fog/vsphere/models/compute/cluster.rb
fog-vsphere-0.2.0 lib/fog/vsphere/models/compute/cluster.rb
fog-vsphere-0.1.1 lib/fog/vsphere/models/compute/cluster.rb
fog-vsphere-0.1.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.35.0 lib/fog/vsphere/models/compute/cluster.rb
fog-2.0.0.pre.0 lib/fog/vsphere/models/compute/cluster.rb
vagrant-cloudstack-1.2.0 vendor/bundle/gems/fog-1.32.0/lib/fog/vsphere/models/compute/cluster.rb
fog-1.34.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.33.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.32.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.31.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.30.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.29.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.28.0 lib/fog/vsphere/models/compute/cluster.rb
fog-1.27.0 lib/fog/vsphere/models/compute/cluster.rb