Creates a new instance of the {HostDevice} 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 [String] :capability The value of attribute `capability`.
@option opts [String] :comment The value of attribute `comment`.
@option opts [String] :description The value of attribute `description`.
@option opts [Host, Hash] :host The value of attribute `host`.
@option opts [String] :id The value of attribute `id`.
@option opts [Integer] :iommu_group The value of attribute `iommu_group`.
@option opts [String] :name The value of attribute `name`.
@option opts [HostDevice, Hash] :parent_device The value of attribute `parent_device`.
@option opts [HostDevice, Hash] :physical_function The value of attribute `physical_function`.
@option opts [Boolean] :placeholder The value of attribute `placeholder`.
@option opts [Product, Hash] :product The value of attribute `product`.
@option opts [Vendor, Hash] :vendor The value of attribute `vendor`.
@option opts [Integer] :virtual_functions The value of attribute `virtual_functions`.
@option opts [Vm, Hash] :vm The value of attribute `vm`.
# File lib/ovirtsdk4/types.rb, line 34561 def initialize(opts = {}) super(opts) self.capability = opts[:capability] self.comment = opts[:comment] self.description = opts[:description] self.host = opts[:host] self.id = opts[:id] self.iommu_group = opts[:iommu_group] self.name = opts[:name] self.parent_device = opts[:parent_device] self.physical_function = opts[:physical_function] self.placeholder = opts[:placeholder] self.product = opts[:product] self.vendor = opts[:vendor] self.virtual_functions = opts[:virtual_functions] self.vm = opts[:vm] end
Returns the value of the `capability` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 34236 def capability return @capability end
Sets the value of the `capability` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 34245 def capability=(value) @capability = value end
Returns the value of the `comment` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 34254 def comment return @comment end
Sets the value of the `comment` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 34263 def comment=(value) @comment = value end
Returns the value of the `description` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 34272 def description return @description end
Sets the value of the `description` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 34281 def description=(value) @description = value end
Returns the value of the `host` attribute.
@return [Host]
# File lib/ovirtsdk4/types.rb, line 34290 def host return @host end
Sets the value of the `host` attribute.
@param value [Host, Hash]
The `value` parameter can be an instance of {OvirtSDK4::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.
# File lib/ovirtsdk4/types.rb, line 34303 def host=(value) if value.is_a?(Hash) value = Host.new(value) end @host = value end
Returns the value of the `id` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 34315 def id return @id end
Sets the value of the `id` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 34324 def id=(value) @id = value end
Returns the value of the `iommu_group` attribute.
@return [Integer]
# File lib/ovirtsdk4/types.rb, line 34333 def iommu_group return @iommu_group end
Sets the value of the `iommu_group` attribute.
@param value [Integer]
# File lib/ovirtsdk4/types.rb, line 34342 def iommu_group=(value) @iommu_group = value end
Returns the value of the `name` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 34351 def name return @name end
Sets the value of the `name` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 34360 def name=(value) @name = value end
Returns the value of the `parent_device` attribute.
@return [HostDevice]
# File lib/ovirtsdk4/types.rb, line 34369 def parent_device return @parent_device end
Sets the value of the `parent_device` attribute.
@param value [HostDevice, Hash]
The `value` parameter can be an instance of {OvirtSDK4::HostDevice} 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 34382 def parent_device=(value) if value.is_a?(Hash) value = HostDevice.new(value) end @parent_device = value end
Returns the value of the `physical_function` attribute.
@return [HostDevice]
# File lib/ovirtsdk4/types.rb, line 34394 def physical_function return @physical_function end
Sets the value of the `physical_function` attribute.
@param value [HostDevice, Hash]
The `value` parameter can be an instance of {OvirtSDK4::HostDevice} 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 34407 def physical_function=(value) if value.is_a?(Hash) value = HostDevice.new(value) end @physical_function = value end
Returns the value of the `placeholder` attribute.
@return [Boolean]
# File lib/ovirtsdk4/types.rb, line 34419 def placeholder return @placeholder end
Sets the value of the `placeholder` attribute.
@param value [Boolean]
# File lib/ovirtsdk4/types.rb, line 34428 def placeholder=(value) @placeholder = value end
Returns the value of the `product` attribute.
@return [Product]
# File lib/ovirtsdk4/types.rb, line 34437 def product return @product end
Sets the value of the `product` attribute.
@param value [Product, Hash]
The `value` parameter can be an instance of {OvirtSDK4::Product} 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 34450 def product=(value) if value.is_a?(Hash) value = Product.new(value) end @product = value end
Returns the value of the `vendor` attribute.
@return [Vendor]
# File lib/ovirtsdk4/types.rb, line 34462 def vendor return @vendor end
Sets the value of the `vendor` attribute.
@param value [Vendor, Hash]
The `value` parameter can be an instance of {OvirtSDK4::Vendor} 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 34475 def vendor=(value) if value.is_a?(Hash) value = Vendor.new(value) end @vendor = value end
Returns the value of the `virtual_functions` attribute.
@return [Integer]
# File lib/ovirtsdk4/types.rb, line 34487 def virtual_functions return @virtual_functions end
Sets the value of the `virtual_functions` attribute.
@param value [Integer]
# File lib/ovirtsdk4/types.rb, line 34496 def virtual_functions=(value) @virtual_functions = value end
Returns the value of the `vm` attribute.
@return [Vm]
# File lib/ovirtsdk4/types.rb, line 34505 def vm return @vm end
Sets the value of the `vm` attribute.
@param value [Vm, Hash]
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.
# File lib/ovirtsdk4/types.rb, line 34518 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end