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.
15001 15002 15003 15004 15005 15006 15007 15008 15009 15010 15011 15012 15013 15014 |
# File 'lib/ovirtsdk4/types.rb', line 15001 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.
15019 15020 15021 15022 15023 15024 15025 15026 15027 15028 15029 15030 15031 15032 |
# File 'lib/ovirtsdk4/types.rb', line 15019 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.
14754 14755 14756 |
# File 'lib/ovirtsdk4/types.rb', line 14754 def address @address end |
#address=(value) ⇒ Object
Sets the value of the address
attribute.
14763 14764 14765 |
# File 'lib/ovirtsdk4/types.rb', line 14763 def address=(value) @address = value end |
#agents ⇒ Array<Agent>
Returns the value of the agents
attribute.
14772 14773 14774 |
# File 'lib/ovirtsdk4/types.rb', line 14772 def agents @agents end |
#agents=(list) ⇒ Object
Sets the value of the agents
attribute.
14781 14782 14783 14784 14785 14786 14787 14788 14789 14790 14791 |
# File 'lib/ovirtsdk4/types.rb', line 14781 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.
14798 14799 14800 |
# File 'lib/ovirtsdk4/types.rb', line 14798 def automatic_pm_enabled @automatic_pm_enabled end |
#automatic_pm_enabled=(value) ⇒ Object
Sets the value of the automatic_pm_enabled
attribute.
14807 14808 14809 |
# File 'lib/ovirtsdk4/types.rb', line 14807 def automatic_pm_enabled=(value) @automatic_pm_enabled = value end |
#enabled ⇒ Boolean
Returns the value of the enabled
attribute.
14816 14817 14818 |
# File 'lib/ovirtsdk4/types.rb', line 14816 def enabled @enabled end |
#enabled=(value) ⇒ Object
Sets the value of the enabled
attribute.
14825 14826 14827 |
# File 'lib/ovirtsdk4/types.rb', line 14825 def enabled=(value) @enabled = value end |
#hash ⇒ Object
Generates a hash value for this object.
15037 15038 15039 15040 15041 15042 15043 15044 15045 15046 15047 15048 15049 15050 |
# File 'lib/ovirtsdk4/types.rb', line 15037 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.
14834 14835 14836 |
# File 'lib/ovirtsdk4/types.rb', line 14834 def kdump_detection @kdump_detection end |
#kdump_detection=(value) ⇒ Object
Sets the value of the kdump_detection
attribute.
14843 14844 14845 |
# File 'lib/ovirtsdk4/types.rb', line 14843 def kdump_detection=(value) @kdump_detection = value end |
#options ⇒ Array<Option>
Returns the value of the options
attribute.
14852 14853 14854 |
# File 'lib/ovirtsdk4/types.rb', line 14852 def @options end |
#options=(list) ⇒ Object
Sets the value of the options
attribute.
14861 14862 14863 14864 14865 14866 14867 14868 14869 14870 14871 |
# File 'lib/ovirtsdk4/types.rb', line 14861 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.
14878 14879 14880 |
# File 'lib/ovirtsdk4/types.rb', line 14878 def password @password end |
#password=(value) ⇒ Object
Sets the value of the password
attribute.
14887 14888 14889 |
# File 'lib/ovirtsdk4/types.rb', line 14887 def password=(value) @password = value end |
#pm_proxies ⇒ Array<PmProxy>
Returns the value of the pm_proxies
attribute.
14896 14897 14898 |
# File 'lib/ovirtsdk4/types.rb', line 14896 def pm_proxies @pm_proxies end |
#pm_proxies=(list) ⇒ Object
Sets the value of the pm_proxies
attribute.
14905 14906 14907 14908 14909 14910 14911 14912 14913 14914 14915 |
# File 'lib/ovirtsdk4/types.rb', line 14905 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.
14922 14923 14924 |
# File 'lib/ovirtsdk4/types.rb', line 14922 def status @status end |
#status=(value) ⇒ Object
Sets the value of the status
attribute.
14931 14932 14933 |
# File 'lib/ovirtsdk4/types.rb', line 14931 def status=(value) @status = value end |
#type ⇒ String
Returns the value of the type
attribute.
14940 14941 14942 |
# File 'lib/ovirtsdk4/types.rb', line 14940 def type @type end |
#type=(value) ⇒ Object
Sets the value of the type
attribute.
14949 14950 14951 |
# File 'lib/ovirtsdk4/types.rb', line 14949 def type=(value) @type = value end |
#username ⇒ String
Returns the value of the username
attribute.
14958 14959 14960 |
# File 'lib/ovirtsdk4/types.rb', line 14958 def username @username end |
#username=(value) ⇒ Object
Sets the value of the username
attribute.
14967 14968 14969 |
# File 'lib/ovirtsdk4/types.rb', line 14967 def username=(value) @username = value end |