Class: OvirtSDK4::Session
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::Session
- 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. -
#console_user ⇒ Boolean
Returns the value of the
console_user
attribute. -
#console_user=(value) ⇒ Object
Sets the value of the
console_user
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 = {}) ⇒ Session
constructor
Creates a new instance of the Session class.
-
#ip ⇒ Ip
Returns the value of the
ip
attribute. -
#ip=(value) ⇒ Object
Sets the value of the
ip
attribute. -
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#protocol ⇒ String
Returns the value of the
protocol
attribute. -
#protocol=(value) ⇒ Object
Sets the value of the
protocol
attribute. -
#user ⇒ User
Returns the value of the
user
attribute. -
#user=(value) ⇒ Object
Sets the value of the
user
attribute. -
#vm ⇒ Vm
Returns the value of the
vm
attribute. -
#vm=(value) ⇒ Object
Sets the value of the
vm
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ Session
Creates a new instance of the OvirtSDK4::Session class.
19036 19037 19038 19039 19040 19041 19042 19043 |
# File 'lib/ovirtsdk4/types.rb', line 19036 def initialize(opts = {}) super(opts) self.console_user = opts[:console_user] self.ip = opts[:ip] self.protocol = opts[:protocol] self.user = opts[:user] self.vm = opts[:vm] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
19048 19049 19050 19051 19052 19053 19054 19055 |
# File 'lib/ovirtsdk4/types.rb', line 19048 def ==(other) super && @console_user == other.console_user && @ip == other.ip && @protocol == other.protocol && @user == other.user && @vm == other.vm end |
#comment ⇒ String
Returns the value of the comment
attribute.
18832 18833 18834 |
# File 'lib/ovirtsdk4/types.rb', line 18832 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
18841 18842 18843 |
# File 'lib/ovirtsdk4/types.rb', line 18841 def comment=(value) @comment = value end |
#console_user ⇒ Boolean
Returns the value of the console_user
attribute.
18850 18851 18852 |
# File 'lib/ovirtsdk4/types.rb', line 18850 def console_user @console_user end |
#console_user=(value) ⇒ Object
Sets the value of the console_user
attribute.
18859 18860 18861 |
# File 'lib/ovirtsdk4/types.rb', line 18859 def console_user=(value) @console_user = value end |
#description ⇒ String
Returns the value of the description
attribute.
18868 18869 18870 |
# File 'lib/ovirtsdk4/types.rb', line 18868 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
18877 18878 18879 |
# File 'lib/ovirtsdk4/types.rb', line 18877 def description=(value) @description = value end |
#hash ⇒ Object
Generates a hash value for this object.
19060 19061 19062 19063 19064 19065 19066 19067 |
# File 'lib/ovirtsdk4/types.rb', line 19060 def hash super + @console_user.hash + @ip.hash + @protocol.hash + @user.hash + @vm.hash end |
#id ⇒ String
Returns the value of the id
attribute.
18886 18887 18888 |
# File 'lib/ovirtsdk4/types.rb', line 18886 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
18895 18896 18897 |
# File 'lib/ovirtsdk4/types.rb', line 18895 def id=(value) @id = value end |
#ip ⇒ Ip
Returns the value of the ip
attribute.
18904 18905 18906 |
# File 'lib/ovirtsdk4/types.rb', line 18904 def ip @ip end |
#ip=(value) ⇒ Object
Sets the value of the ip
attribute.
The value
parameter can be an instance of Ip 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.
18917 18918 18919 18920 18921 18922 |
# File 'lib/ovirtsdk4/types.rb', line 18917 def ip=(value) if value.is_a?(Hash) value = Ip.new(value) end @ip = value end |
#name ⇒ String
Returns the value of the name
attribute.
18929 18930 18931 |
# File 'lib/ovirtsdk4/types.rb', line 18929 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
18938 18939 18940 |
# File 'lib/ovirtsdk4/types.rb', line 18938 def name=(value) @name = value end |
#protocol ⇒ String
Returns the value of the protocol
attribute.
18947 18948 18949 |
# File 'lib/ovirtsdk4/types.rb', line 18947 def protocol @protocol end |
#protocol=(value) ⇒ Object
Sets the value of the protocol
attribute.
18956 18957 18958 |
# File 'lib/ovirtsdk4/types.rb', line 18956 def protocol=(value) @protocol = value end |
#user ⇒ User
Returns the value of the user
attribute.
18965 18966 18967 |
# File 'lib/ovirtsdk4/types.rb', line 18965 def user @user end |
#user=(value) ⇒ Object
Sets the value of the user
attribute.
The value
parameter can be an instance of User 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.
18978 18979 18980 18981 18982 18983 |
# File 'lib/ovirtsdk4/types.rb', line 18978 def user=(value) if value.is_a?(Hash) value = User.new(value) end @user = value end |
#vm ⇒ Vm
Returns the value of the vm
attribute.
18990 18991 18992 |
# File 'lib/ovirtsdk4/types.rb', line 18990 def vm @vm end |
#vm=(value) ⇒ Object
Sets the value of the vm
attribute.
The value
parameter can be an instance of Vm 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.
19003 19004 19005 19006 19007 19008 |
# File 'lib/ovirtsdk4/types.rb', line 19003 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |