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
trueifselfandotherhave the same attributes and values. -
#comment ⇒ String
Returns the value of the
commentattribute. -
#comment=(value) ⇒ Object
Sets the value of the
commentattribute. -
#console_user ⇒ Boolean
Returns the value of the
console_userattribute. -
#console_user=(value) ⇒ Object
Sets the value of the
console_userattribute. -
#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 = {}) ⇒ Session
constructor
Creates a new instance of the Session class.
-
#ip ⇒ Ip
Returns the value of the
ipattribute. -
#ip=(value) ⇒ Object
Sets the value of the
ipattribute. -
#name ⇒ String
Returns the value of the
nameattribute. -
#name=(value) ⇒ Object
Sets the value of the
nameattribute. -
#protocol ⇒ String
Returns the value of the
protocolattribute. -
#protocol=(value) ⇒ Object
Sets the value of the
protocolattribute. -
#user ⇒ User
Returns the value of the
userattribute. -
#user=(value) ⇒ Object
Sets the value of the
userattribute. -
#vm ⇒ Vm
Returns the value of the
vmattribute. -
#vm=(value) ⇒ Object
Sets the value of the
vmattribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ Session
Creates a new instance of the OvirtSDK4::Session class.
19779 19780 19781 19782 19783 19784 19785 19786 |
# File 'lib/ovirtsdk4/types.rb', line 19779 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.
19791 19792 19793 19794 19795 19796 19797 19798 |
# File 'lib/ovirtsdk4/types.rb', line 19791 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.
19575 19576 19577 |
# File 'lib/ovirtsdk4/types.rb', line 19575 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment attribute.
19584 19585 19586 |
# File 'lib/ovirtsdk4/types.rb', line 19584 def comment=(value) @comment = value end |
#console_user ⇒ Boolean
Returns the value of the console_user attribute.
19593 19594 19595 |
# File 'lib/ovirtsdk4/types.rb', line 19593 def console_user @console_user end |
#console_user=(value) ⇒ Object
Sets the value of the console_user attribute.
19602 19603 19604 |
# File 'lib/ovirtsdk4/types.rb', line 19602 def console_user=(value) @console_user = value end |
#description ⇒ String
Returns the value of the description attribute.
19611 19612 19613 |
# File 'lib/ovirtsdk4/types.rb', line 19611 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description attribute.
19620 19621 19622 |
# File 'lib/ovirtsdk4/types.rb', line 19620 def description=(value) @description = value end |
#hash ⇒ Object
Generates a hash value for this object.
19803 19804 19805 19806 19807 19808 19809 19810 |
# File 'lib/ovirtsdk4/types.rb', line 19803 def hash super + @console_user.hash + @ip.hash + @protocol.hash + @user.hash + @vm.hash end |
#id ⇒ String
Returns the value of the id attribute.
19629 19630 19631 |
# File 'lib/ovirtsdk4/types.rb', line 19629 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id attribute.
19638 19639 19640 |
# File 'lib/ovirtsdk4/types.rb', line 19638 def id=(value) @id = value end |
#ip ⇒ Ip
Returns the value of the ip attribute.
19647 19648 19649 |
# File 'lib/ovirtsdk4/types.rb', line 19647 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.
19660 19661 19662 19663 19664 19665 |
# File 'lib/ovirtsdk4/types.rb', line 19660 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.
19672 19673 19674 |
# File 'lib/ovirtsdk4/types.rb', line 19672 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name attribute.
19681 19682 19683 |
# File 'lib/ovirtsdk4/types.rb', line 19681 def name=(value) @name = value end |
#protocol ⇒ String
Returns the value of the protocol attribute.
19690 19691 19692 |
# File 'lib/ovirtsdk4/types.rb', line 19690 def protocol @protocol end |
#protocol=(value) ⇒ Object
Sets the value of the protocol attribute.
19699 19700 19701 |
# File 'lib/ovirtsdk4/types.rb', line 19699 def protocol=(value) @protocol = value end |
#user ⇒ User
Returns the value of the user attribute.
19708 19709 19710 |
# File 'lib/ovirtsdk4/types.rb', line 19708 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.
19721 19722 19723 19724 19725 19726 |
# File 'lib/ovirtsdk4/types.rb', line 19721 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.
19733 19734 19735 |
# File 'lib/ovirtsdk4/types.rb', line 19733 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.
19746 19747 19748 19749 19750 19751 |
# File 'lib/ovirtsdk4/types.rb', line 19746 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |