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.
16972 16973 16974 16975 16976 16977 16978 |
# File 'lib/ovirtsdk4/types.rb', line 16972 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.
16983 16984 16985 16986 16987 16988 16989 |
# File 'lib/ovirtsdk4/types.rb', line 16983 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.
16795 16796 16797 |
# File 'lib/ovirtsdk4/types.rb', line 16795 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
16804 16805 16806 |
# File 'lib/ovirtsdk4/types.rb', line 16804 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
16813 16814 16815 |
# File 'lib/ovirtsdk4/types.rb', line 16813 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
16822 16823 16824 |
# File 'lib/ovirtsdk4/types.rb', line 16822 def description=(value) @description = value end |
#hash ⇒ Object
Generates a hash value for this object.
16994 16995 16996 16997 16998 16999 17000 |
# File 'lib/ovirtsdk4/types.rb', line 16994 def hash super + @limit.hash + @quota.hash + @storage_domain.hash + @usage.hash end |
#id ⇒ String
Returns the value of the id
attribute.
16831 16832 16833 |
# File 'lib/ovirtsdk4/types.rb', line 16831 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
16840 16841 16842 |
# File 'lib/ovirtsdk4/types.rb', line 16840 def id=(value) @id = value end |
#limit ⇒ Integer
Returns the value of the limit
attribute.
16849 16850 16851 |
# File 'lib/ovirtsdk4/types.rb', line 16849 def limit @limit end |
#limit=(value) ⇒ Object
Sets the value of the limit
attribute.
16858 16859 16860 |
# File 'lib/ovirtsdk4/types.rb', line 16858 def limit=(value) @limit = value end |
#name ⇒ String
Returns the value of the name
attribute.
16867 16868 16869 |
# File 'lib/ovirtsdk4/types.rb', line 16867 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
16876 16877 16878 |
# File 'lib/ovirtsdk4/types.rb', line 16876 def name=(value) @name = value end |
#quota ⇒ Quota
Returns the value of the quota
attribute.
16885 16886 16887 |
# File 'lib/ovirtsdk4/types.rb', line 16885 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.
16898 16899 16900 16901 16902 16903 |
# File 'lib/ovirtsdk4/types.rb', line 16898 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.
16910 16911 16912 |
# File 'lib/ovirtsdk4/types.rb', line 16910 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.
16923 16924 16925 16926 16927 16928 |
# File 'lib/ovirtsdk4/types.rb', line 16923 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.
16935 16936 16937 |
# File 'lib/ovirtsdk4/types.rb', line 16935 def usage @usage end |
#usage=(value) ⇒ Object
Sets the value of the usage
attribute.
16944 16945 16946 |
# File 'lib/ovirtsdk4/types.rb', line 16944 def usage=(value) @usage = value end |