Class: OvirtSDK4::HostDevice
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::HostDevice
- 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. -
#capability ⇒ String
Returns the value of the
capability
attribute. -
#capability=(value) ⇒ Object
Sets the value of the
capability
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. -
#driver ⇒ String
Returns the value of the
driver
attribute. -
#driver=(value) ⇒ Object
Sets the value of the
driver
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. -
#initialize(opts = {}) ⇒ HostDevice
constructor
Creates a new instance of the HostDevice class.
-
#iommu_group ⇒ Integer
Returns the value of the
iommu_group
attribute. -
#iommu_group=(value) ⇒ Object
Sets the value of the
iommu_group
attribute. -
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#parent_device ⇒ HostDevice
Returns the value of the
parent_device
attribute. -
#parent_device=(value) ⇒ Object
Sets the value of the
parent_device
attribute. -
#physical_function ⇒ HostDevice
Returns the value of the
physical_function
attribute. -
#physical_function=(value) ⇒ Object
Sets the value of the
physical_function
attribute. -
#placeholder ⇒ Boolean
Returns the value of the
placeholder
attribute. -
#placeholder=(value) ⇒ Object
Sets the value of the
placeholder
attribute. -
#product ⇒ Product
Returns the value of the
product
attribute. -
#product=(value) ⇒ Object
Sets the value of the
product
attribute. -
#vendor ⇒ Vendor
Returns the value of the
vendor
attribute. -
#vendor=(value) ⇒ Object
Sets the value of the
vendor
attribute. -
#virtual_functions ⇒ Integer
Returns the value of the
virtual_functions
attribute. -
#virtual_functions=(value) ⇒ Object
Sets the value of the
virtual_functions
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 = {}) ⇒ HostDevice
Creates a new instance of the OvirtSDK4::HostDevice class.
43001 43002 43003 43004 43005 43006 43007 43008 43009 43010 43011 43012 43013 43014 |
# File 'lib/ovirtsdk4/types.rb', line 43001 def initialize(opts = {}) super(opts) self.capability = opts[:capability] self.driver = opts[:driver] self.host = opts[:host] self.iommu_group = opts[:iommu_group] 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 |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
43019 43020 43021 43022 43023 43024 43025 43026 43027 43028 43029 43030 43031 43032 |
# File 'lib/ovirtsdk4/types.rb', line 43019 def ==(other) super && @capability == other.capability && @driver == other.driver && @host == other.host && @iommu_group == other.iommu_group && @parent_device == other.parent_device && @physical_function == other.physical_function && @placeholder == other.placeholder && @product == other.product && @vendor == other.vendor && @virtual_functions == other.virtual_functions && @vm == other.vm end |
#capability ⇒ String
Returns the value of the capability
attribute.
42656 42657 42658 |
# File 'lib/ovirtsdk4/types.rb', line 42656 def capability @capability end |
#capability=(value) ⇒ Object
Sets the value of the capability
attribute.
42665 42666 42667 |
# File 'lib/ovirtsdk4/types.rb', line 42665 def capability=(value) @capability = value end |
#comment ⇒ String
Returns the value of the comment
attribute.
42674 42675 42676 |
# File 'lib/ovirtsdk4/types.rb', line 42674 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
42683 42684 42685 |
# File 'lib/ovirtsdk4/types.rb', line 42683 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
42692 42693 42694 |
# File 'lib/ovirtsdk4/types.rb', line 42692 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
42701 42702 42703 |
# File 'lib/ovirtsdk4/types.rb', line 42701 def description=(value) @description = value end |
#driver ⇒ String
Returns the value of the driver
attribute.
42710 42711 42712 |
# File 'lib/ovirtsdk4/types.rb', line 42710 def driver @driver end |
#driver=(value) ⇒ Object
Sets the value of the driver
attribute.
42719 42720 42721 |
# File 'lib/ovirtsdk4/types.rb', line 42719 def driver=(value) @driver = value end |
#hash ⇒ Object
Generates a hash value for this object.
43037 43038 43039 43040 43041 43042 43043 43044 43045 43046 43047 43048 43049 43050 |
# File 'lib/ovirtsdk4/types.rb', line 43037 def hash super + @capability.hash + @driver.hash + @host.hash + @iommu_group.hash + @parent_device.hash + @physical_function.hash + @placeholder.hash + @product.hash + @vendor.hash + @virtual_functions.hash + @vm.hash end |
#host ⇒ Host
Returns the value of the host
attribute.
42728 42729 42730 |
# File 'lib/ovirtsdk4/types.rb', line 42728 def host @host end |
#host=(value) ⇒ Object
Sets the value of the host
attribute.
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.
42741 42742 42743 42744 42745 42746 |
# File 'lib/ovirtsdk4/types.rb', line 42741 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.
42753 42754 42755 |
# File 'lib/ovirtsdk4/types.rb', line 42753 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
42762 42763 42764 |
# File 'lib/ovirtsdk4/types.rb', line 42762 def id=(value) @id = value end |
#iommu_group ⇒ Integer
Returns the value of the iommu_group
attribute.
42771 42772 42773 |
# File 'lib/ovirtsdk4/types.rb', line 42771 def iommu_group @iommu_group end |
#iommu_group=(value) ⇒ Object
Sets the value of the iommu_group
attribute.
42780 42781 42782 |
# File 'lib/ovirtsdk4/types.rb', line 42780 def iommu_group=(value) @iommu_group = value end |
#name ⇒ String
Returns the value of the name
attribute.
42789 42790 42791 |
# File 'lib/ovirtsdk4/types.rb', line 42789 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
42798 42799 42800 |
# File 'lib/ovirtsdk4/types.rb', line 42798 def name=(value) @name = value end |
#parent_device ⇒ HostDevice
Returns the value of the parent_device
attribute.
42807 42808 42809 |
# File 'lib/ovirtsdk4/types.rb', line 42807 def parent_device @parent_device end |
#parent_device=(value) ⇒ Object
Sets the value of the parent_device
attribute.
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.
42820 42821 42822 42823 42824 42825 |
# File 'lib/ovirtsdk4/types.rb', line 42820 def parent_device=(value) if value.is_a?(Hash) value = HostDevice.new(value) end @parent_device = value end |
#physical_function ⇒ HostDevice
Returns the value of the physical_function
attribute.
42832 42833 42834 |
# File 'lib/ovirtsdk4/types.rb', line 42832 def physical_function @physical_function end |
#physical_function=(value) ⇒ Object
Sets the value of the physical_function
attribute.
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.
42845 42846 42847 42848 42849 42850 |
# File 'lib/ovirtsdk4/types.rb', line 42845 def physical_function=(value) if value.is_a?(Hash) value = HostDevice.new(value) end @physical_function = value end |
#placeholder ⇒ Boolean
Returns the value of the placeholder
attribute.
42857 42858 42859 |
# File 'lib/ovirtsdk4/types.rb', line 42857 def placeholder @placeholder end |
#placeholder=(value) ⇒ Object
Sets the value of the placeholder
attribute.
42866 42867 42868 |
# File 'lib/ovirtsdk4/types.rb', line 42866 def placeholder=(value) @placeholder = value end |
#product ⇒ Product
Returns the value of the product
attribute.
42875 42876 42877 |
# File 'lib/ovirtsdk4/types.rb', line 42875 def product @product end |
#product=(value) ⇒ Object
Sets the value of the product
attribute.
The value
parameter can be an instance of 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.
42888 42889 42890 42891 42892 42893 |
# File 'lib/ovirtsdk4/types.rb', line 42888 def product=(value) if value.is_a?(Hash) value = Product.new(value) end @product = value end |
#vendor ⇒ Vendor
Returns the value of the vendor
attribute.
42900 42901 42902 |
# File 'lib/ovirtsdk4/types.rb', line 42900 def vendor @vendor end |
#vendor=(value) ⇒ Object
Sets the value of the vendor
attribute.
The value
parameter can be an instance of 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.
42913 42914 42915 42916 42917 42918 |
# File 'lib/ovirtsdk4/types.rb', line 42913 def vendor=(value) if value.is_a?(Hash) value = Vendor.new(value) end @vendor = value end |
#virtual_functions ⇒ Integer
Returns the value of the virtual_functions
attribute.
42925 42926 42927 |
# File 'lib/ovirtsdk4/types.rb', line 42925 def virtual_functions @virtual_functions end |
#virtual_functions=(value) ⇒ Object
Sets the value of the virtual_functions
attribute.
42934 42935 42936 |
# File 'lib/ovirtsdk4/types.rb', line 42934 def virtual_functions=(value) @virtual_functions = value end |
#vm ⇒ Vm
Returns the value of the vm
attribute.
42943 42944 42945 |
# File 'lib/ovirtsdk4/types.rb', line 42943 def vm @vm end |
#vm=(value) ⇒ Object
Sets the value of the vm
attribute.
The value
parameter can be an instance of 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.
42956 42957 42958 42959 42960 42961 |
# File 'lib/ovirtsdk4/types.rb', line 42956 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |