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. -
#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.
26070 26071 26072 26073 26074 26075 26076 26077 26078 26079 26080 26081 26082 26083 26084 26085 26086 26087 |
# File 'lib/ovirtsdk4/types.rb', line 26070 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.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.
26092 26093 26094 26095 26096 26097 26098 26099 26100 26101 26102 26103 26104 26105 26106 26107 26108 26109 |
# File 'lib/ovirtsdk4/types.rb', line 26092 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 && @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.
25637 25638 25639 |
# File 'lib/ovirtsdk4/types.rb', line 25637 def auto_storage_select @auto_storage_select end |
#auto_storage_select=(value) ⇒ Object
Sets the value of the auto_storage_select
attribute.
25646 25647 25648 |
# File 'lib/ovirtsdk4/types.rb', line 25646 def auto_storage_select=(value) @auto_storage_select = value end |
#cluster ⇒ Cluster
Returns the value of the cluster
attribute.
25655 25656 25657 |
# File 'lib/ovirtsdk4/types.rb', line 25655 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.
25668 25669 25670 25671 25672 25673 |
# File 'lib/ovirtsdk4/types.rb', line 25668 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.
25680 25681 25682 |
# File 'lib/ovirtsdk4/types.rb', line 25680 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
25689 25690 25691 |
# File 'lib/ovirtsdk4/types.rb', line 25689 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
25698 25699 25700 |
# File 'lib/ovirtsdk4/types.rb', line 25698 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
25707 25708 25709 |
# File 'lib/ovirtsdk4/types.rb', line 25707 def description=(value) @description = value end |
#display ⇒ Display
Returns the value of the display
attribute.
25716 25717 25718 |
# File 'lib/ovirtsdk4/types.rb', line 25716 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.
25729 25730 25731 25732 25733 25734 |
# File 'lib/ovirtsdk4/types.rb', line 25729 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.
26114 26115 26116 26117 26118 26119 26120 26121 26122 26123 26124 26125 26126 26127 26128 26129 26130 26131 |
# File 'lib/ovirtsdk4/types.rb', line 26114 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 + @type.hash + @use_latest_template_version.hash + @vm.hash end |
#id ⇒ String
Returns the value of the id
attribute.
25741 25742 25743 |
# File 'lib/ovirtsdk4/types.rb', line 25741 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
25750 25751 25752 |
# File 'lib/ovirtsdk4/types.rb', line 25750 def id=(value) @id = value end |
#instance_type ⇒ InstanceType
Returns the value of the instance_type
attribute.
25759 25760 25761 |
# File 'lib/ovirtsdk4/types.rb', line 25759 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.
25772 25773 25774 25775 25776 25777 |
# File 'lib/ovirtsdk4/types.rb', line 25772 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.
25784 25785 25786 |
# File 'lib/ovirtsdk4/types.rb', line 25784 def max_user_vms @max_user_vms end |
#max_user_vms=(value) ⇒ Object
Sets the value of the max_user_vms
attribute.
25793 25794 25795 |
# File 'lib/ovirtsdk4/types.rb', line 25793 def max_user_vms=(value) @max_user_vms = value end |
#name ⇒ String
Returns the value of the name
attribute.
25802 25803 25804 |
# File 'lib/ovirtsdk4/types.rb', line 25802 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
25811 25812 25813 |
# File 'lib/ovirtsdk4/types.rb', line 25811 def name=(value) @name = value end |
#permissions ⇒ Array<Permission>
Returns the value of the permissions
attribute.
25820 25821 25822 |
# File 'lib/ovirtsdk4/types.rb', line 25820 def @permissions end |
#permissions=(list) ⇒ Object
Sets the value of the permissions
attribute.
25829 25830 25831 25832 25833 25834 25835 25836 25837 25838 25839 |
# File 'lib/ovirtsdk4/types.rb', line 25829 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.
25846 25847 25848 |
# File 'lib/ovirtsdk4/types.rb', line 25846 def prestarted_vms @prestarted_vms end |
#prestarted_vms=(value) ⇒ Object
Sets the value of the prestarted_vms
attribute.
25855 25856 25857 |
# File 'lib/ovirtsdk4/types.rb', line 25855 def prestarted_vms=(value) @prestarted_vms = value end |
#rng_device ⇒ RngDevice
Returns the value of the rng_device
attribute.
25864 25865 25866 |
# File 'lib/ovirtsdk4/types.rb', line 25864 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.
25877 25878 25879 25880 25881 25882 |
# File 'lib/ovirtsdk4/types.rb', line 25877 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.
25889 25890 25891 |
# File 'lib/ovirtsdk4/types.rb', line 25889 def size @size end |
#size=(value) ⇒ Object
Sets the value of the size
attribute.
25898 25899 25900 |
# File 'lib/ovirtsdk4/types.rb', line 25898 def size=(value) @size = value end |
#soundcard_enabled ⇒ Boolean
Returns the value of the soundcard_enabled
attribute.
25907 25908 25909 |
# File 'lib/ovirtsdk4/types.rb', line 25907 def soundcard_enabled @soundcard_enabled end |
#soundcard_enabled=(value) ⇒ Object
Sets the value of the soundcard_enabled
attribute.
25916 25917 25918 |
# File 'lib/ovirtsdk4/types.rb', line 25916 def soundcard_enabled=(value) @soundcard_enabled = value end |
#stateful ⇒ Boolean
Returns the value of the stateful
attribute.
25925 25926 25927 |
# File 'lib/ovirtsdk4/types.rb', line 25925 def stateful @stateful end |
#stateful=(value) ⇒ Object
Sets the value of the stateful
attribute.
25934 25935 25936 |
# File 'lib/ovirtsdk4/types.rb', line 25934 def stateful=(value) @stateful = value end |
#template ⇒ Template
Returns the value of the template
attribute.
25943 25944 25945 |
# File 'lib/ovirtsdk4/types.rb', line 25943 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.
25956 25957 25958 25959 25960 25961 |
# File 'lib/ovirtsdk4/types.rb', line 25956 def template=(value) if value.is_a?(Hash) value = Template.new(value) end @template = value end |
#type ⇒ VmPoolType
Returns the value of the type
attribute.
25968 25969 25970 |
# File 'lib/ovirtsdk4/types.rb', line 25968 def type @type end |
#type=(value) ⇒ Object
Sets the value of the type
attribute.
25977 25978 25979 |
# File 'lib/ovirtsdk4/types.rb', line 25977 def type=(value) @type = value end |
#use_latest_template_version ⇒ Boolean
Returns the value of the use_latest_template_version
attribute.
25986 25987 25988 |
# File 'lib/ovirtsdk4/types.rb', line 25986 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.
25995 25996 25997 |
# File 'lib/ovirtsdk4/types.rb', line 25995 def use_latest_template_version=(value) @use_latest_template_version = value end |
#vm ⇒ Vm
Returns the value of the vm
attribute.
26004 26005 26006 |
# File 'lib/ovirtsdk4/types.rb', line 26004 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.
26017 26018 26019 26020 26021 26022 |
# File 'lib/ovirtsdk4/types.rb', line 26017 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |