class OvirtSDK4::NumaNodePin

Public Class Methods

new(opts = {}) click to toggle source

Creates a new instance of the {NumaNodePin} class.

@param opts [Hash] A hash containing the attributes of the object. The keys of the hash

should be symbols corresponding to the names of the attributes. The values of the hash
should be the values of the attributes.

@option opts [NumaNode, Hash] :host_numa_node The value of attribute `host_numa_node`.

@option opts [Integer] :index The value of attribute `index`.

@option opts [Boolean] :pinned The value of attribute `pinned`.

Calls superclass method OvirtSDK4::Struct.new
# File lib/ovirtsdk4/types.rb, line 10853
def initialize(opts = {})
  super(opts)
  self.host_numa_node = opts[:host_numa_node]
  self.index = opts[:index]
  self.pinned = opts[:pinned]
end

Public Instance Methods

==(other) click to toggle source

Returns `true` if `self` and `other` have the same attributes and values.

Calls superclass method OvirtSDK4::Struct#==
# File lib/ovirtsdk4/types.rb, line 10863
def ==(other)
  super &&
  @host_numa_node == other.host_numa_node &&
  @index == other.index &&
  @pinned == other.pinned
end
hash() click to toggle source

Generates a hash value for this object.

Calls superclass method OvirtSDK4::Struct#hash
# File lib/ovirtsdk4/types.rb, line 10873
def hash
  super +
  @host_numa_node.hash +
  @index.hash +
  @pinned.hash
end
host_numa_node() click to toggle source

Returns the value of the `host_numa_node` attribute.

@return [NumaNode]

# File lib/ovirtsdk4/types.rb, line 10783
def host_numa_node
  @host_numa_node
end
host_numa_node=(value) click to toggle source

Sets the value of the `host_numa_node` attribute.

@param value [NumaNode, Hash]

The `value` parameter can be an instance of {OvirtSDK4::NumaNode} 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.

# File lib/ovirtsdk4/types.rb, line 10796
def host_numa_node=(value)
  if value.is_a?(Hash)
    value = NumaNode.new(value)
  end
  @host_numa_node = value
end
index() click to toggle source

Returns the value of the `index` attribute.

@return [Integer]

# File lib/ovirtsdk4/types.rb, line 10808
def index
  @index
end
index=(value) click to toggle source

Sets the value of the `index` attribute.

@param value [Integer]

# File lib/ovirtsdk4/types.rb, line 10817
def index=(value)
  @index = value
end
pinned() click to toggle source

Returns the value of the `pinned` attribute.

@return [Boolean]

# File lib/ovirtsdk4/types.rb, line 10826
def pinned
  @pinned
end
pinned=(value) click to toggle source

Sets the value of the `pinned` attribute.

@param value [Boolean]

# File lib/ovirtsdk4/types.rb, line 10835
def pinned=(value)
  @pinned = value
end