Class: OvirtSDK4::VirtualNumaNode
- Inherits:
-
NumaNode
- Object
- Struct
- Identified
- NumaNode
- OvirtSDK4::VirtualNumaNode
- 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. -
#comment ⇒ String
Returns the value of the
comment
attribute. -
#comment=(value) ⇒ Object
Sets the value of the
comment
attribute. -
#cpu ⇒ Cpu
Returns the value of the
cpu
attribute. -
#cpu=(value) ⇒ Object
Sets the value of the
cpu
attribute. -
#description ⇒ String
Returns the value of the
description
attribute. -
#description=(value) ⇒ Object
Sets the value of the
description
attribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#host ⇒ Host
Returns the value of the
host
attribute. -
#host=(value) ⇒ Object
Sets the value of the
host
attribute. -
#id ⇒ String
Returns the value of the
id
attribute. -
#id=(value) ⇒ Object
Sets the value of the
id
attribute. -
#index ⇒ Integer
Returns the value of the
index
attribute. -
#index=(value) ⇒ Object
Sets the value of the
index
attribute. -
#initialize(opts = {}) ⇒ VirtualNumaNode
constructor
Creates a new instance of the VirtualNumaNode class.
-
#memory ⇒ Integer
Returns the value of the
memory
attribute. -
#memory=(value) ⇒ Object
Sets the value of the
memory
attribute. -
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#node_distance ⇒ String
Returns the value of the
node_distance
attribute. -
#node_distance=(value) ⇒ Object
Sets the value of the
node_distance
attribute. -
#numa_node_pins ⇒ Array<NumaNodePin>
Returns the value of the
numa_node_pins
attribute. -
#numa_node_pins=(list) ⇒ Object
Sets the value of the
numa_node_pins
attribute. -
#numa_tune_mode ⇒ NumaTuneMode
Returns the value of the
numa_tune_mode
attribute. -
#numa_tune_mode=(value) ⇒ Object
Sets the value of the
numa_tune_mode
attribute. -
#statistics ⇒ Array<Statistic>
Returns the value of the
statistics
attribute. -
#statistics=(list) ⇒ Object
Sets the value of the
statistics
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 = {}) ⇒ VirtualNumaNode
Creates a new instance of the OvirtSDK4::VirtualNumaNode class.
24980 24981 24982 24983 24984 24985 |
# File 'lib/ovirtsdk4/types.rb', line 24980 def initialize(opts = {}) super(opts) self.numa_node_pins = opts[:numa_node_pins] self.numa_tune_mode = opts[:numa_tune_mode] self.vm = opts[:vm] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
24990 24991 24992 24993 24994 24995 |
# File 'lib/ovirtsdk4/types.rb', line 24990 def ==(other) super && @numa_node_pins == other.numa_node_pins && @numa_tune_mode == other.numa_tune_mode && @vm == other.vm end |
#comment ⇒ String
Returns the value of the comment
attribute.
24680 24681 24682 |
# File 'lib/ovirtsdk4/types.rb', line 24680 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
24689 24690 24691 |
# File 'lib/ovirtsdk4/types.rb', line 24689 def comment=(value) @comment = value end |
#cpu ⇒ Cpu
Returns the value of the cpu
attribute.
24698 24699 24700 |
# File 'lib/ovirtsdk4/types.rb', line 24698 def cpu @cpu end |
#cpu=(value) ⇒ Object
Sets the value of the cpu
attribute.
The value
parameter can be an instance of Cpu 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.
24711 24712 24713 24714 24715 24716 |
# File 'lib/ovirtsdk4/types.rb', line 24711 def cpu=(value) if value.is_a?(Hash) value = Cpu.new(value) end @cpu = value end |
#description ⇒ String
Returns the value of the description
attribute.
24723 24724 24725 |
# File 'lib/ovirtsdk4/types.rb', line 24723 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
24732 24733 24734 |
# File 'lib/ovirtsdk4/types.rb', line 24732 def description=(value) @description = value end |
#hash ⇒ Object
Generates a hash value for this object.
25000 25001 25002 25003 25004 25005 |
# File 'lib/ovirtsdk4/types.rb', line 25000 def hash super + @numa_node_pins.hash + @numa_tune_mode.hash + @vm.hash end |
#host ⇒ Host
Returns the value of the host
attribute.
24741 24742 24743 |
# File 'lib/ovirtsdk4/types.rb', line 24741 def host @host end |
#host=(value) ⇒ Object
Sets the value of the host
attribute.
The value
parameter can be an instance of Host 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.
24754 24755 24756 24757 24758 24759 |
# File 'lib/ovirtsdk4/types.rb', line 24754 def host=(value) if value.is_a?(Hash) value = Host.new(value) end @host = value end |
#id ⇒ String
Returns the value of the id
attribute.
24766 24767 24768 |
# File 'lib/ovirtsdk4/types.rb', line 24766 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
24775 24776 24777 |
# File 'lib/ovirtsdk4/types.rb', line 24775 def id=(value) @id = value end |
#index ⇒ Integer
Returns the value of the index
attribute.
24784 24785 24786 |
# File 'lib/ovirtsdk4/types.rb', line 24784 def index @index end |
#index=(value) ⇒ Object
Sets the value of the index
attribute.
24793 24794 24795 |
# File 'lib/ovirtsdk4/types.rb', line 24793 def index=(value) @index = value end |
#memory ⇒ Integer
Returns the value of the memory
attribute.
24802 24803 24804 |
# File 'lib/ovirtsdk4/types.rb', line 24802 def memory @memory end |
#memory=(value) ⇒ Object
Sets the value of the memory
attribute.
24811 24812 24813 |
# File 'lib/ovirtsdk4/types.rb', line 24811 def memory=(value) @memory = value end |
#name ⇒ String
Returns the value of the name
attribute.
24820 24821 24822 |
# File 'lib/ovirtsdk4/types.rb', line 24820 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
24829 24830 24831 |
# File 'lib/ovirtsdk4/types.rb', line 24829 def name=(value) @name = value end |
#node_distance ⇒ String
Returns the value of the node_distance
attribute.
24838 24839 24840 |
# File 'lib/ovirtsdk4/types.rb', line 24838 def node_distance @node_distance end |
#node_distance=(value) ⇒ Object
Sets the value of the node_distance
attribute.
24847 24848 24849 |
# File 'lib/ovirtsdk4/types.rb', line 24847 def node_distance=(value) @node_distance = value end |
#numa_node_pins ⇒ Array<NumaNodePin>
Returns the value of the numa_node_pins
attribute.
24856 24857 24858 |
# File 'lib/ovirtsdk4/types.rb', line 24856 def numa_node_pins @numa_node_pins end |
#numa_node_pins=(list) ⇒ Object
Sets the value of the numa_node_pins
attribute.
24865 24866 24867 24868 24869 24870 24871 24872 24873 24874 24875 |
# File 'lib/ovirtsdk4/types.rb', line 24865 def numa_node_pins=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = NumaNodePin.new(value) end end end @numa_node_pins = list end |
#numa_tune_mode ⇒ NumaTuneMode
Returns the value of the numa_tune_mode
attribute.
24882 24883 24884 |
# File 'lib/ovirtsdk4/types.rb', line 24882 def numa_tune_mode @numa_tune_mode end |
#numa_tune_mode=(value) ⇒ Object
Sets the value of the numa_tune_mode
attribute.
24891 24892 24893 |
# File 'lib/ovirtsdk4/types.rb', line 24891 def numa_tune_mode=(value) @numa_tune_mode = value end |
#statistics ⇒ Array<Statistic>
Returns the value of the statistics
attribute.
24900 24901 24902 |
# File 'lib/ovirtsdk4/types.rb', line 24900 def statistics @statistics end |
#statistics=(list) ⇒ Object
Sets the value of the statistics
attribute.
24909 24910 24911 24912 24913 24914 24915 24916 24917 24918 24919 |
# File 'lib/ovirtsdk4/types.rb', line 24909 def statistics=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Statistic.new(value) end end end @statistics = list end |
#vm ⇒ Vm
Returns the value of the vm
attribute.
24926 24927 24928 |
# File 'lib/ovirtsdk4/types.rb', line 24926 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.
24939 24940 24941 24942 24943 24944 |
# File 'lib/ovirtsdk4/types.rb', line 24939 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |