Class: OvirtSDK4::Group
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::Group
- 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. -
#description ⇒ String
Returns the value of the
descriptionattribute. -
#description=(value) ⇒ Object
Sets the value of the
descriptionattribute. -
#domain ⇒ Domain
Returns the value of the
domainattribute. -
#domain=(value) ⇒ Object
Sets the value of the
domainattribute. -
#domain_entry_id ⇒ String
Returns the value of the
domain_entry_idattribute. -
#domain_entry_id=(value) ⇒ Object
Sets the value of the
domain_entry_idattribute. -
#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 = {}) ⇒ Group
constructor
Creates a new instance of the Group class.
-
#name ⇒ String
Returns the value of the
nameattribute. -
#name=(value) ⇒ Object
Sets the value of the
nameattribute. -
#namespace ⇒ String
Returns the value of the
namespaceattribute. -
#namespace=(value) ⇒ Object
Sets the value of the
namespaceattribute. -
#permissions ⇒ Array<Permission>
Returns the value of the
permissionsattribute. -
#permissions=(list) ⇒ Object
Sets the value of the
permissionsattribute. -
#roles ⇒ Array<Role>
Returns the value of the
rolesattribute. -
#roles=(list) ⇒ Object
Sets the value of the
rolesattribute. -
#tags ⇒ Array<Tag>
Returns the value of the
tagsattribute. -
#tags=(list) ⇒ Object
Sets the value of the
tagsattribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ Group
Creates a new instance of the OvirtSDK4::Group class.
40866 40867 40868 40869 40870 40871 40872 40873 40874 |
# File 'lib/ovirtsdk4/types.rb', line 40866 def initialize(opts = {}) super(opts) self.domain = opts[:domain] self.domain_entry_id = opts[:domain_entry_id] self.namespace = opts[:namespace] self. = opts[:permissions] self.roles = opts[:roles] self. = opts[:tags] end |
Instance Method Details
#==(other) ⇒ Object
Returns true if self and other have the same attributes and values.
40879 40880 40881 40882 40883 40884 40885 40886 40887 |
# File 'lib/ovirtsdk4/types.rb', line 40879 def ==(other) super && @domain == other.domain && @domain_entry_id == other.domain_entry_id && @namespace == other.namespace && == other. && @roles == other.roles && == other. end |
#comment ⇒ String
Returns the value of the comment attribute.
40632 40633 40634 |
# File 'lib/ovirtsdk4/types.rb', line 40632 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment attribute.
40641 40642 40643 |
# File 'lib/ovirtsdk4/types.rb', line 40641 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description attribute.
40650 40651 40652 |
# File 'lib/ovirtsdk4/types.rb', line 40650 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description attribute.
40659 40660 40661 |
# File 'lib/ovirtsdk4/types.rb', line 40659 def description=(value) @description = value end |
#domain ⇒ Domain
Returns the value of the domain attribute.
40668 40669 40670 |
# File 'lib/ovirtsdk4/types.rb', line 40668 def domain @domain end |
#domain=(value) ⇒ Object
Sets the value of the domain attribute.
The value parameter can be an instance of Domain 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.
40681 40682 40683 40684 40685 40686 |
# File 'lib/ovirtsdk4/types.rb', line 40681 def domain=(value) if value.is_a?(Hash) value = Domain.new(value) end @domain = value end |
#domain_entry_id ⇒ String
Returns the value of the domain_entry_id attribute.
40693 40694 40695 |
# File 'lib/ovirtsdk4/types.rb', line 40693 def domain_entry_id @domain_entry_id end |
#domain_entry_id=(value) ⇒ Object
Sets the value of the domain_entry_id attribute.
40702 40703 40704 |
# File 'lib/ovirtsdk4/types.rb', line 40702 def domain_entry_id=(value) @domain_entry_id = value end |
#hash ⇒ Object
Generates a hash value for this object.
40892 40893 40894 40895 40896 40897 40898 40899 40900 |
# File 'lib/ovirtsdk4/types.rb', line 40892 def hash super + @domain.hash + @domain_entry_id.hash + @namespace.hash + .hash + @roles.hash + .hash end |
#id ⇒ String
Returns the value of the id attribute.
40711 40712 40713 |
# File 'lib/ovirtsdk4/types.rb', line 40711 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id attribute.
40720 40721 40722 |
# File 'lib/ovirtsdk4/types.rb', line 40720 def id=(value) @id = value end |
#name ⇒ String
Returns the value of the name attribute.
40729 40730 40731 |
# File 'lib/ovirtsdk4/types.rb', line 40729 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name attribute.
40738 40739 40740 |
# File 'lib/ovirtsdk4/types.rb', line 40738 def name=(value) @name = value end |
#namespace ⇒ String
Returns the value of the namespace attribute.
40747 40748 40749 |
# File 'lib/ovirtsdk4/types.rb', line 40747 def namespace @namespace end |
#namespace=(value) ⇒ Object
Sets the value of the namespace attribute.
40756 40757 40758 |
# File 'lib/ovirtsdk4/types.rb', line 40756 def namespace=(value) @namespace = value end |
#permissions ⇒ Array<Permission>
Returns the value of the permissions attribute.
40765 40766 40767 |
# File 'lib/ovirtsdk4/types.rb', line 40765 def end |
#permissions=(list) ⇒ Object
Sets the value of the permissions attribute.
40774 40775 40776 40777 40778 40779 40780 40781 40782 40783 40784 |
# File 'lib/ovirtsdk4/types.rb', line 40774 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 |
#roles ⇒ Array<Role>
Returns the value of the roles attribute.
40791 40792 40793 |
# File 'lib/ovirtsdk4/types.rb', line 40791 def roles @roles end |
#roles=(list) ⇒ Object
Sets the value of the roles attribute.
40800 40801 40802 40803 40804 40805 40806 40807 40808 40809 40810 |
# File 'lib/ovirtsdk4/types.rb', line 40800 def roles=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Role.new(value) end end end @roles = list end |
#tags ⇒ Array<Tag>
Returns the value of the tags attribute.
40817 40818 40819 |
# File 'lib/ovirtsdk4/types.rb', line 40817 def end |
#tags=(list) ⇒ Object
Sets the value of the tags attribute.
40826 40827 40828 40829 40830 40831 40832 40833 40834 40835 40836 |
# File 'lib/ovirtsdk4/types.rb', line 40826 def (list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Tag.new(value) end end end = list end |