Class: OvirtSDK4::QuotaStorageLimit
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::QuotaStorageLimit
- 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. -
#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. -
#hash ⇒ Object
Generates a hash value for this object.
-
#id ⇒ String
Returns the value of the
id
attribute. -
#id=(value) ⇒ Object
Sets the value of the
id
attribute. -
#initialize(opts = {}) ⇒ QuotaStorageLimit
constructor
Creates a new instance of the QuotaStorageLimit class.
-
#limit ⇒ Integer
Returns the value of the
limit
attribute. -
#limit=(value) ⇒ Object
Sets the value of the
limit
attribute. -
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#quota ⇒ Quota
Returns the value of the
quota
attribute. -
#quota=(value) ⇒ Object
Sets the value of the
quota
attribute. -
#storage_domain ⇒ StorageDomain
Returns the value of the
storage_domain
attribute. -
#storage_domain=(value) ⇒ Object
Sets the value of the
storage_domain
attribute. -
#usage ⇒ Float
Returns the value of the
usage
attribute. -
#usage=(value) ⇒ Object
Sets the value of the
usage
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ QuotaStorageLimit
Creates a new instance of the OvirtSDK4::QuotaStorageLimit class.
16499 16500 16501 16502 16503 16504 16505 |
# File 'lib/ovirtsdk4/types.rb', line 16499 def initialize(opts = {}) super(opts) self.limit = opts[:limit] self.quota = opts[:quota] self.storage_domain = opts[:storage_domain] self.usage = opts[:usage] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
16510 16511 16512 16513 16514 16515 16516 |
# File 'lib/ovirtsdk4/types.rb', line 16510 def ==(other) super && @limit == other.limit && @quota == other.quota && @storage_domain == other.storage_domain && @usage == other.usage end |
#comment ⇒ String
Returns the value of the comment
attribute.
16322 16323 16324 |
# File 'lib/ovirtsdk4/types.rb', line 16322 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
16331 16332 16333 |
# File 'lib/ovirtsdk4/types.rb', line 16331 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
16340 16341 16342 |
# File 'lib/ovirtsdk4/types.rb', line 16340 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
16349 16350 16351 |
# File 'lib/ovirtsdk4/types.rb', line 16349 def description=(value) @description = value end |
#hash ⇒ Object
Generates a hash value for this object.
16521 16522 16523 16524 16525 16526 16527 |
# File 'lib/ovirtsdk4/types.rb', line 16521 def hash super + @limit.hash + @quota.hash + @storage_domain.hash + @usage.hash end |
#id ⇒ String
Returns the value of the id
attribute.
16358 16359 16360 |
# File 'lib/ovirtsdk4/types.rb', line 16358 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
16367 16368 16369 |
# File 'lib/ovirtsdk4/types.rb', line 16367 def id=(value) @id = value end |
#limit ⇒ Integer
Returns the value of the limit
attribute.
16376 16377 16378 |
# File 'lib/ovirtsdk4/types.rb', line 16376 def limit @limit end |
#limit=(value) ⇒ Object
Sets the value of the limit
attribute.
16385 16386 16387 |
# File 'lib/ovirtsdk4/types.rb', line 16385 def limit=(value) @limit = value end |
#name ⇒ String
Returns the value of the name
attribute.
16394 16395 16396 |
# File 'lib/ovirtsdk4/types.rb', line 16394 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
16403 16404 16405 |
# File 'lib/ovirtsdk4/types.rb', line 16403 def name=(value) @name = value end |
#quota ⇒ Quota
Returns the value of the quota
attribute.
16412 16413 16414 |
# File 'lib/ovirtsdk4/types.rb', line 16412 def quota @quota end |
#quota=(value) ⇒ Object
Sets the value of the quota
attribute.
The value
parameter can be an instance of OvirtSDK4::Quota 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.
16425 16426 16427 16428 16429 16430 |
# File 'lib/ovirtsdk4/types.rb', line 16425 def quota=(value) if value.is_a?(Hash) value = Quota.new(value) end @quota = value end |
#storage_domain ⇒ StorageDomain
Returns the value of the storage_domain
attribute.
16437 16438 16439 |
# File 'lib/ovirtsdk4/types.rb', line 16437 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 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.
16450 16451 16452 16453 16454 16455 |
# File 'lib/ovirtsdk4/types.rb', line 16450 def storage_domain=(value) if value.is_a?(Hash) value = StorageDomain.new(value) end @storage_domain = value end |
#usage ⇒ Float
Returns the value of the usage
attribute.
16462 16463 16464 |
# File 'lib/ovirtsdk4/types.rb', line 16462 def usage @usage end |
#usage=(value) ⇒ Object
Sets the value of the usage
attribute.
16471 16472 16473 |
# File 'lib/ovirtsdk4/types.rb', line 16471 def usage=(value) @usage = value end |