Class: OvirtSDK4::StorageDomainLease
- 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. -
#hash ⇒ Object
Generates a hash value for this object.
-
#initialize(opts = {}) ⇒ StorageDomainLease
constructor
Creates a new instance of the StorageDomainLease class.
-
#storage_domain ⇒ StorageDomain
Returns the value of the
storage_domain
attribute. -
#storage_domain=(value) ⇒ Object
Sets the value of the
storage_domain
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ StorageDomainLease
Creates a new instance of the OvirtSDK4::StorageDomainLease class.
22806 22807 22808 22809 |
# File 'lib/ovirtsdk4/types.rb', line 22806 def initialize(opts = {}) super(opts) self.storage_domain = opts[:storage_domain] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
22814 22815 22816 22817 |
# File 'lib/ovirtsdk4/types.rb', line 22814 def ==(other) super && @storage_domain == other.storage_domain end |
#hash ⇒ Object
Generates a hash value for this object.
22822 22823 22824 22825 |
# File 'lib/ovirtsdk4/types.rb', line 22822 def hash super + @storage_domain.hash end |
#storage_domain ⇒ StorageDomain
Returns the value of the storage_domain
attribute.
22776 22777 22778 |
# File 'lib/ovirtsdk4/types.rb', line 22776 def storage_domain @storage_domain end |
#storage_domain=(value) ⇒ Object
Sets the value of the storage_domain
attribute.
The value
parameter can be an instance of OvirtSDK4::StorageDomain 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.
22789 22790 22791 22792 22793 22794 |
# File 'lib/ovirtsdk4/types.rb', line 22789 def storage_domain=(value) if value.is_a?(Hash) value = StorageDomain.new(value) end @storage_domain = value end |