Class: OvirtSDK4::DataCenter
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::DataCenter
- Defined in:
- lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb
Instance Method Summary collapse
-
#==(other) ⇒ Object
Returns
trueifselfandotherhave the same attributes and values. -
#clusters ⇒ Array<Cluster>
Returns the value of the
clustersattribute. -
#clusters=(list) ⇒ Object
Sets the value of the
clustersattribute. -
#comment ⇒ String
Returns the value of the
commentattribute. -
#comment=(value) ⇒ Object
Sets the value of the
commentattribute. -
#description ⇒ String
Returns the value of the
descriptionattribute. -
#description=(value) ⇒ Object
Sets the value of the
descriptionattribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#id ⇒ String
Returns the value of the
idattribute. -
#id=(value) ⇒ Object
Sets the value of the
idattribute. -
#initialize(opts = {}) ⇒ DataCenter
constructor
Creates a new instance of the DataCenter class.
-
#iscsi_bonds ⇒ Array<IscsiBond>
Returns the value of the
iscsi_bondsattribute. -
#iscsi_bonds=(list) ⇒ Object
Sets the value of the
iscsi_bondsattribute. -
#local ⇒ Boolean
Returns the value of the
localattribute. -
#local=(value) ⇒ Object
Sets the value of the
localattribute. -
#mac_pool ⇒ MacPool
Returns the value of the
mac_poolattribute. -
#mac_pool=(value) ⇒ Object
Sets the value of the
mac_poolattribute. -
#name ⇒ String
Returns the value of the
nameattribute. -
#name=(value) ⇒ Object
Sets the value of the
nameattribute. -
#networks ⇒ Array<Network>
Returns the value of the
networksattribute. -
#networks=(list) ⇒ Object
Sets the value of the
networksattribute. -
#permissions ⇒ Array<Permission>
Returns the value of the
permissionsattribute. -
#permissions=(list) ⇒ Object
Sets the value of the
permissionsattribute. -
#qoss ⇒ Array<Qos>
Returns the value of the
qossattribute. -
#qoss=(list) ⇒ Object
Sets the value of the
qossattribute. -
#quota_mode ⇒ QuotaModeType
Returns the value of the
quota_modeattribute. -
#quota_mode=(value) ⇒ Object
Sets the value of the
quota_modeattribute. -
#quotas ⇒ Array<Quota>
Returns the value of the
quotasattribute. -
#quotas=(list) ⇒ Object
Sets the value of the
quotasattribute. -
#status ⇒ DataCenterStatus
Returns the value of the
statusattribute. -
#status=(value) ⇒ Object
Sets the value of the
statusattribute. -
#storage_domains ⇒ Array<StorageDomain>
Returns the value of the
storage_domainsattribute. -
#storage_domains=(list) ⇒ Object
Sets the value of the
storage_domainsattribute. -
#storage_format ⇒ StorageFormat
Returns the value of the
storage_formatattribute. -
#storage_format=(value) ⇒ Object
Sets the value of the
storage_formatattribute. -
#supported_versions ⇒ Array<Version>
Returns the value of the
supported_versionsattribute. -
#supported_versions=(list) ⇒ Object
Sets the value of the
supported_versionsattribute. -
#version ⇒ Version
Returns the value of the
versionattribute. -
#version=(value) ⇒ Object
Sets the value of the
versionattribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ DataCenter
Creates a new instance of the OvirtSDK4::DataCenter class.
36075 36076 36077 36078 36079 36080 36081 36082 36083 36084 36085 36086 36087 36088 36089 36090 36091 |
# File 'lib/ovirtsdk4/types.rb', line 36075 def initialize(opts = {}) super(opts) self.clusters = opts[:clusters] self.iscsi_bonds = opts[:iscsi_bonds] self.local = opts[:local] self.mac_pool = opts[:mac_pool] self.networks = opts[:networks] self. = opts[:permissions] self.qoss = opts[:qoss] self.quota_mode = opts[:quota_mode] self.quotas = opts[:quotas] self.status = opts[:status] self.storage_domains = opts[:storage_domains] self.storage_format = opts[:storage_format] self.supported_versions = opts[:supported_versions] self.version = opts[:version] end |
Instance Method Details
#==(other) ⇒ Object
Returns true if self and other have the same attributes and values.
36096 36097 36098 36099 36100 36101 36102 36103 36104 36105 36106 36107 36108 36109 36110 36111 36112 |
# File 'lib/ovirtsdk4/types.rb', line 36096 def ==(other) super && @clusters == other.clusters && @iscsi_bonds == other.iscsi_bonds && @local == other.local && @mac_pool == other.mac_pool && @networks == other.networks && == other. && @qoss == other.qoss && @quota_mode == other.quota_mode && @quotas == other.quotas && @status == other.status && @storage_domains == other.storage_domains && @storage_format == other.storage_format && @supported_versions == other.supported_versions && @version == other.version end |
#clusters ⇒ Array<Cluster>
Returns the value of the clusters attribute.
35634 35635 35636 |
# File 'lib/ovirtsdk4/types.rb', line 35634 def clusters @clusters end |
#clusters=(list) ⇒ Object
Sets the value of the clusters attribute.
35643 35644 35645 35646 35647 35648 35649 35650 35651 35652 35653 |
# File 'lib/ovirtsdk4/types.rb', line 35643 def clusters=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Cluster.new(value) end end end @clusters = list end |
#comment ⇒ String
Returns the value of the comment attribute.
35660 35661 35662 |
# File 'lib/ovirtsdk4/types.rb', line 35660 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment attribute.
35669 35670 35671 |
# File 'lib/ovirtsdk4/types.rb', line 35669 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description attribute.
35678 35679 35680 |
# File 'lib/ovirtsdk4/types.rb', line 35678 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description attribute.
35687 35688 35689 |
# File 'lib/ovirtsdk4/types.rb', line 35687 def description=(value) @description = value end |
#hash ⇒ Object
Generates a hash value for this object.
36117 36118 36119 36120 36121 36122 36123 36124 36125 36126 36127 36128 36129 36130 36131 36132 36133 |
# File 'lib/ovirtsdk4/types.rb', line 36117 def hash super + @clusters.hash + @iscsi_bonds.hash + @local.hash + @mac_pool.hash + @networks.hash + .hash + @qoss.hash + @quota_mode.hash + @quotas.hash + @status.hash + @storage_domains.hash + @storage_format.hash + @supported_versions.hash + @version.hash end |
#id ⇒ String
Returns the value of the id attribute.
35696 35697 35698 |
# File 'lib/ovirtsdk4/types.rb', line 35696 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id attribute.
35705 35706 35707 |
# File 'lib/ovirtsdk4/types.rb', line 35705 def id=(value) @id = value end |
#iscsi_bonds ⇒ Array<IscsiBond>
Returns the value of the iscsi_bonds attribute.
35714 35715 35716 |
# File 'lib/ovirtsdk4/types.rb', line 35714 def iscsi_bonds @iscsi_bonds end |
#iscsi_bonds=(list) ⇒ Object
Sets the value of the iscsi_bonds attribute.
35723 35724 35725 35726 35727 35728 35729 35730 35731 35732 35733 |
# File 'lib/ovirtsdk4/types.rb', line 35723 def iscsi_bonds=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = IscsiBond.new(value) end end end @iscsi_bonds = list end |
#local ⇒ Boolean
Returns the value of the local attribute.
35740 35741 35742 |
# File 'lib/ovirtsdk4/types.rb', line 35740 def local @local end |
#local=(value) ⇒ Object
Sets the value of the local attribute.
35749 35750 35751 |
# File 'lib/ovirtsdk4/types.rb', line 35749 def local=(value) @local = value end |
#mac_pool ⇒ MacPool
Returns the value of the mac_pool attribute.
35758 35759 35760 |
# File 'lib/ovirtsdk4/types.rb', line 35758 def mac_pool @mac_pool end |
#mac_pool=(value) ⇒ Object
Sets the value of the mac_pool attribute.
The value parameter can be an instance of MacPool 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.
35771 35772 35773 35774 35775 35776 |
# File 'lib/ovirtsdk4/types.rb', line 35771 def mac_pool=(value) if value.is_a?(Hash) value = MacPool.new(value) end @mac_pool = value end |
#name ⇒ String
Returns the value of the name attribute.
35783 35784 35785 |
# File 'lib/ovirtsdk4/types.rb', line 35783 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name attribute.
35792 35793 35794 |
# File 'lib/ovirtsdk4/types.rb', line 35792 def name=(value) @name = value end |
#networks ⇒ Array<Network>
Returns the value of the networks attribute.
35801 35802 35803 |
# File 'lib/ovirtsdk4/types.rb', line 35801 def networks @networks end |
#networks=(list) ⇒ Object
Sets the value of the networks attribute.
35810 35811 35812 35813 35814 35815 35816 35817 35818 35819 35820 |
# File 'lib/ovirtsdk4/types.rb', line 35810 def networks=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Network.new(value) end end end @networks = list end |
#permissions ⇒ Array<Permission>
Returns the value of the permissions attribute.
35827 35828 35829 |
# File 'lib/ovirtsdk4/types.rb', line 35827 def end |
#permissions=(list) ⇒ Object
Sets the value of the permissions attribute.
35836 35837 35838 35839 35840 35841 35842 35843 35844 35845 35846 |
# File 'lib/ovirtsdk4/types.rb', line 35836 def (list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Permission.new(value) end end end = list end |
#qoss ⇒ Array<Qos>
Returns the value of the qoss attribute.
35853 35854 35855 |
# File 'lib/ovirtsdk4/types.rb', line 35853 def qoss @qoss end |
#qoss=(list) ⇒ Object
Sets the value of the qoss attribute.
35862 35863 35864 35865 35866 35867 35868 35869 35870 35871 35872 |
# File 'lib/ovirtsdk4/types.rb', line 35862 def qoss=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Qos.new(value) end end end @qoss = list end |
#quota_mode ⇒ QuotaModeType
Returns the value of the quota_mode attribute.
35879 35880 35881 |
# File 'lib/ovirtsdk4/types.rb', line 35879 def quota_mode @quota_mode end |
#quota_mode=(value) ⇒ Object
Sets the value of the quota_mode attribute.
35888 35889 35890 |
# File 'lib/ovirtsdk4/types.rb', line 35888 def quota_mode=(value) @quota_mode = value end |
#quotas ⇒ Array<Quota>
Returns the value of the quotas attribute.
35897 35898 35899 |
# File 'lib/ovirtsdk4/types.rb', line 35897 def quotas @quotas end |
#quotas=(list) ⇒ Object
Sets the value of the quotas attribute.
35906 35907 35908 35909 35910 35911 35912 35913 35914 35915 35916 |
# File 'lib/ovirtsdk4/types.rb', line 35906 def quotas=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Quota.new(value) end end end @quotas = list end |
#status ⇒ DataCenterStatus
Returns the value of the status attribute.
35923 35924 35925 |
# File 'lib/ovirtsdk4/types.rb', line 35923 def status @status end |
#status=(value) ⇒ Object
Sets the value of the status attribute.
35932 35933 35934 |
# File 'lib/ovirtsdk4/types.rb', line 35932 def status=(value) @status = value end |
#storage_domains ⇒ Array<StorageDomain>
Returns the value of the storage_domains attribute.
35941 35942 35943 |
# File 'lib/ovirtsdk4/types.rb', line 35941 def storage_domains @storage_domains end |
#storage_domains=(list) ⇒ Object
Sets the value of the storage_domains attribute.
35950 35951 35952 35953 35954 35955 35956 35957 35958 35959 35960 |
# File 'lib/ovirtsdk4/types.rb', line 35950 def storage_domains=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = StorageDomain.new(value) end end end @storage_domains = list end |
#storage_format ⇒ StorageFormat
Returns the value of the storage_format attribute.
35967 35968 35969 |
# File 'lib/ovirtsdk4/types.rb', line 35967 def storage_format @storage_format end |
#storage_format=(value) ⇒ Object
Sets the value of the storage_format attribute.
35976 35977 35978 |
# File 'lib/ovirtsdk4/types.rb', line 35976 def storage_format=(value) @storage_format = value end |
#supported_versions ⇒ Array<Version>
Returns the value of the supported_versions attribute.
35985 35986 35987 |
# File 'lib/ovirtsdk4/types.rb', line 35985 def supported_versions @supported_versions end |
#supported_versions=(list) ⇒ Object
Sets the value of the supported_versions attribute.
35994 35995 35996 35997 35998 35999 36000 36001 36002 36003 36004 |
# File 'lib/ovirtsdk4/types.rb', line 35994 def supported_versions=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Version.new(value) end end end @supported_versions = list end |
#version ⇒ Version
Returns the value of the version attribute.
36011 36012 36013 |
# File 'lib/ovirtsdk4/types.rb', line 36011 def version @version end |
#version=(value) ⇒ Object
Sets the value of the version attribute.
The value parameter can be an instance of Version 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.
36024 36025 36026 36027 36028 36029 |
# File 'lib/ovirtsdk4/types.rb', line 36024 def version=(value) if value.is_a?(Hash) value = Version.new(value) end @version = value end |