Class: OvirtSDK4::VmPool
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::VmPool
- Defined in:
- lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb
Instance Method Summary collapse
-
#==(other) ⇒ Object
Returns
true
ifself
andother
have the same attributes and values. -
#auto_storage_select ⇒ Boolean
Returns the value of the
auto_storage_select
attribute. -
#auto_storage_select=(value) ⇒ Object
Sets the value of the
auto_storage_select
attribute. -
#cluster ⇒ Cluster
Returns the value of the
cluster
attribute. -
#cluster=(value) ⇒ Object
Sets the value of the
cluster
attribute. -
#comment ⇒ String
Returns the value of the
comment
attribute. -
#comment=(value) ⇒ Object
Sets the value of the
comment
attribute. -
#description ⇒ String
Returns the value of the
description
attribute. -
#description=(value) ⇒ Object
Sets the value of the
description
attribute. -
#display ⇒ Display
Returns the value of the
display
attribute. -
#display=(value) ⇒ Object
Sets the value of the
display
attribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#id ⇒ String
Returns the value of the
id
attribute. -
#id=(value) ⇒ Object
Sets the value of the
id
attribute. -
#initialize(opts = {}) ⇒ VmPool
constructor
Creates a new instance of the VmPool class.
-
#instance_type ⇒ InstanceType
Returns the value of the
instance_type
attribute. -
#instance_type=(value) ⇒ Object
Sets the value of the
instance_type
attribute. -
#max_user_vms ⇒ Integer
Returns the value of the
max_user_vms
attribute. -
#max_user_vms=(value) ⇒ Object
Sets the value of the
max_user_vms
attribute. -
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#permissions ⇒ Array<Permission>
Returns the value of the
permissions
attribute. -
#permissions=(list) ⇒ Object
Sets the value of the
permissions
attribute. -
#prestarted_vms ⇒ Integer
Returns the value of the
prestarted_vms
attribute. -
#prestarted_vms=(value) ⇒ Object
Sets the value of the
prestarted_vms
attribute. -
#rng_device ⇒ RngDevice
Returns the value of the
rng_device
attribute. -
#rng_device=(value) ⇒ Object
Sets the value of the
rng_device
attribute. -
#size ⇒ Integer
Returns the value of the
size
attribute. -
#size=(value) ⇒ Object
Sets the value of the
size
attribute. -
#soundcard_enabled ⇒ Boolean
Returns the value of the
soundcard_enabled
attribute. -
#soundcard_enabled=(value) ⇒ Object
Sets the value of the
soundcard_enabled
attribute. -
#stateful ⇒ Boolean
Returns the value of the
stateful
attribute. -
#stateful=(value) ⇒ Object
Sets the value of the
stateful
attribute. -
#template ⇒ Template
Returns the value of the
template
attribute. -
#template=(value) ⇒ Object
Sets the value of the
template
attribute. -
#tpm_enabled ⇒ Boolean
Returns the value of the
tpm_enabled
attribute. -
#tpm_enabled=(value) ⇒ Object
Sets the value of the
tpm_enabled
attribute. -
#type ⇒ VmPoolType
Returns the value of the
type
attribute. -
#type=(value) ⇒ Object
Sets the value of the
type
attribute. -
#use_latest_template_version ⇒ Boolean
Returns the value of the
use_latest_template_version
attribute. -
#use_latest_template_version=(value) ⇒ Object
Sets the value of the
use_latest_template_version
attribute. -
#vm ⇒ Vm
Returns the value of the
vm
attribute. -
#vm=(value) ⇒ Object
Sets the value of the
vm
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ VmPool
Creates a new instance of the OvirtSDK4::VmPool class.
27460 27461 27462 27463 27464 27465 27466 27467 27468 27469 27470 27471 27472 27473 27474 27475 27476 27477 27478 |
# File 'lib/ovirtsdk4/types.rb', line 27460 def initialize(opts = {}) super(opts) self.auto_storage_select = opts[:auto_storage_select] self.cluster = opts[:cluster] self.display = opts[:display] self.instance_type = opts[:instance_type] self.max_user_vms = opts[:max_user_vms] self. = opts[:permissions] self.prestarted_vms = opts[:prestarted_vms] self.rng_device = opts[:rng_device] self.size = opts[:size] self.soundcard_enabled = opts[:soundcard_enabled] self.stateful = opts[:stateful] self.template = opts[:template] self.tpm_enabled = opts[:tpm_enabled] self.type = opts[:type] self.use_latest_template_version = opts[:use_latest_template_version] self.vm = opts[:vm] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
27483 27484 27485 27486 27487 27488 27489 27490 27491 27492 27493 27494 27495 27496 27497 27498 27499 27500 27501 |
# File 'lib/ovirtsdk4/types.rb', line 27483 def ==(other) super && @auto_storage_select == other.auto_storage_select && @cluster == other.cluster && @display == other.display && @instance_type == other.instance_type && @max_user_vms == other.max_user_vms && @permissions == other. && @prestarted_vms == other.prestarted_vms && @rng_device == other.rng_device && @size == other.size && @soundcard_enabled == other.soundcard_enabled && @stateful == other.stateful && @template == other.template && @tpm_enabled == other.tpm_enabled && @type == other.type && @use_latest_template_version == other.use_latest_template_version && @vm == other.vm end |
#auto_storage_select ⇒ Boolean
Returns the value of the auto_storage_select
attribute.
27007 27008 27009 |
# File 'lib/ovirtsdk4/types.rb', line 27007 def auto_storage_select @auto_storage_select end |
#auto_storage_select=(value) ⇒ Object
Sets the value of the auto_storage_select
attribute.
27016 27017 27018 |
# File 'lib/ovirtsdk4/types.rb', line 27016 def auto_storage_select=(value) @auto_storage_select = value end |
#cluster ⇒ Cluster
Returns the value of the cluster
attribute.
27025 27026 27027 |
# File 'lib/ovirtsdk4/types.rb', line 27025 def cluster @cluster end |
#cluster=(value) ⇒ Object
Sets the value of the cluster
attribute.
The value
parameter can be an instance of Cluster or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
27038 27039 27040 27041 27042 27043 |
# File 'lib/ovirtsdk4/types.rb', line 27038 def cluster=(value) if value.is_a?(Hash) value = Cluster.new(value) end @cluster = value end |
#comment ⇒ String
Returns the value of the comment
attribute.
27050 27051 27052 |
# File 'lib/ovirtsdk4/types.rb', line 27050 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
27059 27060 27061 |
# File 'lib/ovirtsdk4/types.rb', line 27059 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
27068 27069 27070 |
# File 'lib/ovirtsdk4/types.rb', line 27068 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
27077 27078 27079 |
# File 'lib/ovirtsdk4/types.rb', line 27077 def description=(value) @description = value end |
#display ⇒ Display
Returns the value of the display
attribute.
27086 27087 27088 |
# File 'lib/ovirtsdk4/types.rb', line 27086 def display @display end |
#display=(value) ⇒ Object
Sets the value of the display
attribute.
The value
parameter can be an instance of Display or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
27099 27100 27101 27102 27103 27104 |
# File 'lib/ovirtsdk4/types.rb', line 27099 def display=(value) if value.is_a?(Hash) value = Display.new(value) end @display = value end |
#hash ⇒ Object
Generates a hash value for this object.
27506 27507 27508 27509 27510 27511 27512 27513 27514 27515 27516 27517 27518 27519 27520 27521 27522 27523 27524 |
# File 'lib/ovirtsdk4/types.rb', line 27506 def hash super + @auto_storage_select.hash + @cluster.hash + @display.hash + @instance_type.hash + @max_user_vms.hash + @permissions.hash + @prestarted_vms.hash + @rng_device.hash + @size.hash + @soundcard_enabled.hash + @stateful.hash + @template.hash + @tpm_enabled.hash + @type.hash + @use_latest_template_version.hash + @vm.hash end |
#id ⇒ String
Returns the value of the id
attribute.
27111 27112 27113 |
# File 'lib/ovirtsdk4/types.rb', line 27111 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
27120 27121 27122 |
# File 'lib/ovirtsdk4/types.rb', line 27120 def id=(value) @id = value end |
#instance_type ⇒ InstanceType
Returns the value of the instance_type
attribute.
27129 27130 27131 |
# File 'lib/ovirtsdk4/types.rb', line 27129 def instance_type @instance_type end |
#instance_type=(value) ⇒ Object
Sets the value of the instance_type
attribute.
The value
parameter can be an instance of InstanceType or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
27142 27143 27144 27145 27146 27147 |
# File 'lib/ovirtsdk4/types.rb', line 27142 def instance_type=(value) if value.is_a?(Hash) value = InstanceType.new(value) end @instance_type = value end |
#max_user_vms ⇒ Integer
Returns the value of the max_user_vms
attribute.
27154 27155 27156 |
# File 'lib/ovirtsdk4/types.rb', line 27154 def max_user_vms @max_user_vms end |
#max_user_vms=(value) ⇒ Object
Sets the value of the max_user_vms
attribute.
27163 27164 27165 |
# File 'lib/ovirtsdk4/types.rb', line 27163 def max_user_vms=(value) @max_user_vms = value end |
#name ⇒ String
Returns the value of the name
attribute.
27172 27173 27174 |
# File 'lib/ovirtsdk4/types.rb', line 27172 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
27181 27182 27183 |
# File 'lib/ovirtsdk4/types.rb', line 27181 def name=(value) @name = value end |
#permissions ⇒ Array<Permission>
Returns the value of the permissions
attribute.
27190 27191 27192 |
# File 'lib/ovirtsdk4/types.rb', line 27190 def @permissions end |
#permissions=(list) ⇒ Object
Sets the value of the permissions
attribute.
27199 27200 27201 27202 27203 27204 27205 27206 27207 27208 27209 |
# File 'lib/ovirtsdk4/types.rb', line 27199 def (list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Permission.new(value) end end end @permissions = list end |
#prestarted_vms ⇒ Integer
Returns the value of the prestarted_vms
attribute.
27216 27217 27218 |
# File 'lib/ovirtsdk4/types.rb', line 27216 def prestarted_vms @prestarted_vms end |
#prestarted_vms=(value) ⇒ Object
Sets the value of the prestarted_vms
attribute.
27225 27226 27227 |
# File 'lib/ovirtsdk4/types.rb', line 27225 def prestarted_vms=(value) @prestarted_vms = value end |
#rng_device ⇒ RngDevice
Returns the value of the rng_device
attribute.
27234 27235 27236 |
# File 'lib/ovirtsdk4/types.rb', line 27234 def rng_device @rng_device end |
#rng_device=(value) ⇒ Object
Sets the value of the rng_device
attribute.
The value
parameter can be an instance of RngDevice or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
27247 27248 27249 27250 27251 27252 |
# File 'lib/ovirtsdk4/types.rb', line 27247 def rng_device=(value) if value.is_a?(Hash) value = RngDevice.new(value) end @rng_device = value end |
#size ⇒ Integer
Returns the value of the size
attribute.
27259 27260 27261 |
# File 'lib/ovirtsdk4/types.rb', line 27259 def size @size end |
#size=(value) ⇒ Object
Sets the value of the size
attribute.
27268 27269 27270 |
# File 'lib/ovirtsdk4/types.rb', line 27268 def size=(value) @size = value end |
#soundcard_enabled ⇒ Boolean
Returns the value of the soundcard_enabled
attribute.
27277 27278 27279 |
# File 'lib/ovirtsdk4/types.rb', line 27277 def soundcard_enabled @soundcard_enabled end |
#soundcard_enabled=(value) ⇒ Object
Sets the value of the soundcard_enabled
attribute.
27286 27287 27288 |
# File 'lib/ovirtsdk4/types.rb', line 27286 def soundcard_enabled=(value) @soundcard_enabled = value end |
#stateful ⇒ Boolean
Returns the value of the stateful
attribute.
27295 27296 27297 |
# File 'lib/ovirtsdk4/types.rb', line 27295 def stateful @stateful end |
#stateful=(value) ⇒ Object
Sets the value of the stateful
attribute.
27304 27305 27306 |
# File 'lib/ovirtsdk4/types.rb', line 27304 def stateful=(value) @stateful = value end |
#template ⇒ Template
Returns the value of the template
attribute.
27313 27314 27315 |
# File 'lib/ovirtsdk4/types.rb', line 27313 def template @template end |
#template=(value) ⇒ Object
Sets the value of the template
attribute.
The value
parameter can be an instance of Template or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
27326 27327 27328 27329 27330 27331 |
# File 'lib/ovirtsdk4/types.rb', line 27326 def template=(value) if value.is_a?(Hash) value = Template.new(value) end @template = value end |
#tpm_enabled ⇒ Boolean
Returns the value of the tpm_enabled
attribute.
27338 27339 27340 |
# File 'lib/ovirtsdk4/types.rb', line 27338 def tpm_enabled @tpm_enabled end |
#tpm_enabled=(value) ⇒ Object
Sets the value of the tpm_enabled
attribute.
27347 27348 27349 |
# File 'lib/ovirtsdk4/types.rb', line 27347 def tpm_enabled=(value) @tpm_enabled = value end |
#type ⇒ VmPoolType
Returns the value of the type
attribute.
27356 27357 27358 |
# File 'lib/ovirtsdk4/types.rb', line 27356 def type @type end |
#type=(value) ⇒ Object
Sets the value of the type
attribute.
27365 27366 27367 |
# File 'lib/ovirtsdk4/types.rb', line 27365 def type=(value) @type = value end |
#use_latest_template_version ⇒ Boolean
Returns the value of the use_latest_template_version
attribute.
27374 27375 27376 |
# File 'lib/ovirtsdk4/types.rb', line 27374 def use_latest_template_version @use_latest_template_version end |
#use_latest_template_version=(value) ⇒ Object
Sets the value of the use_latest_template_version
attribute.
27383 27384 27385 |
# File 'lib/ovirtsdk4/types.rb', line 27383 def use_latest_template_version=(value) @use_latest_template_version = value end |
#vm ⇒ Vm
Returns the value of the vm
attribute.
27392 27393 27394 |
# File 'lib/ovirtsdk4/types.rb', line 27392 def vm @vm end |
#vm=(value) ⇒ Object
Sets the value of the vm
attribute.
The value
parameter can be an instance of OvirtSDK4::Vm or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
27405 27406 27407 27408 27409 27410 |
# File 'lib/ovirtsdk4/types.rb', line 27405 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |