Class: OvirtSDK4::CpuTune
- Inherits:
-
Struct
- Object
- Struct
- OvirtSDK4::CpuTune
- Defined in:
- lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb
Instance Method Summary (collapse)
-
- (CpuTune) initialize(opts = {})
constructor
Creates a new instance of the CpuTune class.
-
- (Array<VcpuPin>) vcpu_pins
Returns the value of the
vcpu_pins
attribute. -
- (Object) vcpu_pins=(list)
Sets the value of the
vcpu_pins
attribute.
Methods included from Type
Constructor Details
- (CpuTune) initialize(opts = {})
Creates a new instance of the OvirtSDK4::CpuTune class.
1968 1969 1970 1971 |
# File 'lib/ovirtsdk4/types.rb', line 1968 def initialize(opts = {}) super(opts) self.vcpu_pins = opts[:vcpu_pins] end |
Instance Method Details
- (Array<VcpuPin>) vcpu_pins
Returns the value of the vcpu_pins
attribute.
1938 1939 1940 |
# File 'lib/ovirtsdk4/types.rb', line 1938 def vcpu_pins return @vcpu_pins end |
- (Object) vcpu_pins=(list)
Sets the value of the vcpu_pins
attribute.
1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 |
# File 'lib/ovirtsdk4/types.rb', line 1946 def vcpu_pins=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = VcpuPin.new(value) end end end @vcpu_pins = list end |