Class: OvirtSDK4::PowerManagement
- 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. -
#address ⇒ String
Returns the value of the
address
attribute. -
#address=(value) ⇒ Object
Sets the value of the
address
attribute. -
#agents ⇒ Array<Agent>
Returns the value of the
agents
attribute. -
#agents=(list) ⇒ Object
Sets the value of the
agents
attribute. -
#automatic_pm_enabled ⇒ Boolean
Returns the value of the
automatic_pm_enabled
attribute. -
#automatic_pm_enabled=(value) ⇒ Object
Sets the value of the
automatic_pm_enabled
attribute. -
#enabled ⇒ Boolean
Returns the value of the
enabled
attribute. -
#enabled=(value) ⇒ Object
Sets the value of the
enabled
attribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#initialize(opts = {}) ⇒ PowerManagement
constructor
Creates a new instance of the PowerManagement class.
-
#kdump_detection ⇒ Boolean
Returns the value of the
kdump_detection
attribute. -
#kdump_detection=(value) ⇒ Object
Sets the value of the
kdump_detection
attribute. -
#options ⇒ Array<Option>
Returns the value of the
options
attribute. -
#options=(list) ⇒ Object
Sets the value of the
options
attribute. -
#password ⇒ String
Returns the value of the
password
attribute. -
#password=(value) ⇒ Object
Sets the value of the
password
attribute. -
#pm_proxies ⇒ Array<PmProxy>
Returns the value of the
pm_proxies
attribute. -
#pm_proxies=(list) ⇒ Object
Sets the value of the
pm_proxies
attribute. -
#status ⇒ PowerManagementStatus
Returns the value of the
status
attribute. -
#status=(value) ⇒ Object
Sets the value of the
status
attribute. -
#type ⇒ String
Returns the value of the
type
attribute. -
#type=(value) ⇒ Object
Sets the value of the
type
attribute. -
#username ⇒ String
Returns the value of the
username
attribute. -
#username=(value) ⇒ Object
Sets the value of the
username
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ PowerManagement
Creates a new instance of the OvirtSDK4::PowerManagement class.
14143 14144 14145 14146 14147 14148 14149 14150 14151 14152 14153 14154 14155 14156 |
# File 'lib/ovirtsdk4/types.rb', line 14143 def initialize(opts = {}) super(opts) self.address = opts[:address] self.agents = opts[:agents] self.automatic_pm_enabled = opts[:automatic_pm_enabled] self.enabled = opts[:enabled] self.kdump_detection = opts[:kdump_detection] self. = opts[:options] self.password = opts[:password] self.pm_proxies = opts[:pm_proxies] self.status = opts[:status] self.type = opts[:type] self.username = opts[:username] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
14161 14162 14163 14164 14165 14166 14167 14168 14169 14170 14171 14172 14173 14174 |
# File 'lib/ovirtsdk4/types.rb', line 14161 def ==(other) super && @address == other.address && @agents == other.agents && @automatic_pm_enabled == other.automatic_pm_enabled && @enabled == other.enabled && @kdump_detection == other.kdump_detection && @options == other. && @password == other.password && @pm_proxies == other.pm_proxies && @status == other.status && @type == other.type && @username == other.username end |
#address ⇒ String
Returns the value of the address
attribute.
13896 13897 13898 |
# File 'lib/ovirtsdk4/types.rb', line 13896 def address @address end |
#address=(value) ⇒ Object
Sets the value of the address
attribute.
13905 13906 13907 |
# File 'lib/ovirtsdk4/types.rb', line 13905 def address=(value) @address = value end |
#agents ⇒ Array<Agent>
Returns the value of the agents
attribute.
13914 13915 13916 |
# File 'lib/ovirtsdk4/types.rb', line 13914 def agents @agents end |
#agents=(list) ⇒ Object
Sets the value of the agents
attribute.
13923 13924 13925 13926 13927 13928 13929 13930 13931 13932 13933 |
# File 'lib/ovirtsdk4/types.rb', line 13923 def agents=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Agent.new(value) end end end @agents = list end |
#automatic_pm_enabled ⇒ Boolean
Returns the value of the automatic_pm_enabled
attribute.
13940 13941 13942 |
# File 'lib/ovirtsdk4/types.rb', line 13940 def automatic_pm_enabled @automatic_pm_enabled end |
#automatic_pm_enabled=(value) ⇒ Object
Sets the value of the automatic_pm_enabled
attribute.
13949 13950 13951 |
# File 'lib/ovirtsdk4/types.rb', line 13949 def automatic_pm_enabled=(value) @automatic_pm_enabled = value end |
#enabled ⇒ Boolean
Returns the value of the enabled
attribute.
13958 13959 13960 |
# File 'lib/ovirtsdk4/types.rb', line 13958 def enabled @enabled end |
#enabled=(value) ⇒ Object
Sets the value of the enabled
attribute.
13967 13968 13969 |
# File 'lib/ovirtsdk4/types.rb', line 13967 def enabled=(value) @enabled = value end |
#hash ⇒ Object
Generates a hash value for this object.
14179 14180 14181 14182 14183 14184 14185 14186 14187 14188 14189 14190 14191 14192 |
# File 'lib/ovirtsdk4/types.rb', line 14179 def hash super + @address.hash + @agents.hash + @automatic_pm_enabled.hash + @enabled.hash + @kdump_detection.hash + @options.hash + @password.hash + @pm_proxies.hash + @status.hash + @type.hash + @username.hash end |
#kdump_detection ⇒ Boolean
Returns the value of the kdump_detection
attribute.
13976 13977 13978 |
# File 'lib/ovirtsdk4/types.rb', line 13976 def kdump_detection @kdump_detection end |
#kdump_detection=(value) ⇒ Object
Sets the value of the kdump_detection
attribute.
13985 13986 13987 |
# File 'lib/ovirtsdk4/types.rb', line 13985 def kdump_detection=(value) @kdump_detection = value end |
#options ⇒ Array<Option>
Returns the value of the options
attribute.
13994 13995 13996 |
# File 'lib/ovirtsdk4/types.rb', line 13994 def @options end |
#options=(list) ⇒ Object
Sets the value of the options
attribute.
14003 14004 14005 14006 14007 14008 14009 14010 14011 14012 14013 |
# File 'lib/ovirtsdk4/types.rb', line 14003 def (list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Option.new(value) end end end @options = list end |
#password ⇒ String
Returns the value of the password
attribute.
14020 14021 14022 |
# File 'lib/ovirtsdk4/types.rb', line 14020 def password @password end |
#password=(value) ⇒ Object
Sets the value of the password
attribute.
14029 14030 14031 |
# File 'lib/ovirtsdk4/types.rb', line 14029 def password=(value) @password = value end |
#pm_proxies ⇒ Array<PmProxy>
Returns the value of the pm_proxies
attribute.
14038 14039 14040 |
# File 'lib/ovirtsdk4/types.rb', line 14038 def pm_proxies @pm_proxies end |
#pm_proxies=(list) ⇒ Object
Sets the value of the pm_proxies
attribute.
14047 14048 14049 14050 14051 14052 14053 14054 14055 14056 14057 |
# File 'lib/ovirtsdk4/types.rb', line 14047 def pm_proxies=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = PmProxy.new(value) end end end @pm_proxies = list end |
#status ⇒ PowerManagementStatus
Returns the value of the status
attribute.
14064 14065 14066 |
# File 'lib/ovirtsdk4/types.rb', line 14064 def status @status end |
#status=(value) ⇒ Object
Sets the value of the status
attribute.
14073 14074 14075 |
# File 'lib/ovirtsdk4/types.rb', line 14073 def status=(value) @status = value end |
#type ⇒ String
Returns the value of the type
attribute.
14082 14083 14084 |
# File 'lib/ovirtsdk4/types.rb', line 14082 def type @type end |
#type=(value) ⇒ Object
Sets the value of the type
attribute.
14091 14092 14093 |
# File 'lib/ovirtsdk4/types.rb', line 14091 def type=(value) @type = value end |
#username ⇒ String
Returns the value of the username
attribute.
14100 14101 14102 |
# File 'lib/ovirtsdk4/types.rb', line 14100 def username @username end |
#username=(value) ⇒ Object
Sets the value of the username
attribute.
14109 14110 14111 |
# File 'lib/ovirtsdk4/types.rb', line 14109 def username=(value) @username = value end |