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
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. -
#description ⇒ String
Returns the value of the
description
attribute. -
#description=(value) ⇒ Object
Sets the value of the
description
attribute. -
#domain ⇒ Domain
Returns the value of the
domain
attribute. -
#domain=(value) ⇒ Object
Sets the value of the
domain
attribute. -
#domain_entry_id ⇒ String
Returns the value of the
domain_entry_id
attribute. -
#domain_entry_id=(value) ⇒ Object
Sets the value of the
domain_entry_id
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 = {}) ⇒ Group
constructor
Creates a new instance of the Group class.
-
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#namespace ⇒ String
Returns the value of the
namespace
attribute. -
#namespace=(value) ⇒ Object
Sets the value of the
namespace
attribute. -
#permissions ⇒ Array<Permission>
Returns the value of the
permissions
attribute. -
#permissions=(list) ⇒ Object
Sets the value of the
permissions
attribute. -
#roles ⇒ Array<Role>
Returns the value of the
roles
attribute. -
#roles=(list) ⇒ Object
Sets the value of the
roles
attribute. -
#tags ⇒ Array<Tag>
Returns the value of the
tags
attribute. -
#tags=(list) ⇒ Object
Sets the value of the
tags
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ Group
Creates a new instance of the OvirtSDK4::Group class.
43962 43963 43964 43965 43966 43967 43968 43969 43970 |
# File 'lib/ovirtsdk4/types.rb', line 43962 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.
43975 43976 43977 43978 43979 43980 43981 43982 43983 |
# File 'lib/ovirtsdk4/types.rb', line 43975 def ==(other) super && @domain == other.domain && @domain_entry_id == other.domain_entry_id && @namespace == other.namespace && @permissions == other. && @roles == other.roles && @tags == other. end |
#comment ⇒ String
Returns the value of the comment
attribute.
43728 43729 43730 |
# File 'lib/ovirtsdk4/types.rb', line 43728 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
43737 43738 43739 |
# File 'lib/ovirtsdk4/types.rb', line 43737 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
43746 43747 43748 |
# File 'lib/ovirtsdk4/types.rb', line 43746 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
43755 43756 43757 |
# File 'lib/ovirtsdk4/types.rb', line 43755 def description=(value) @description = value end |
#domain ⇒ Domain
Returns the value of the domain
attribute.
43764 43765 43766 |
# File 'lib/ovirtsdk4/types.rb', line 43764 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.
43777 43778 43779 43780 43781 43782 |
# File 'lib/ovirtsdk4/types.rb', line 43777 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.
43789 43790 43791 |
# File 'lib/ovirtsdk4/types.rb', line 43789 def domain_entry_id @domain_entry_id end |
#domain_entry_id=(value) ⇒ Object
Sets the value of the domain_entry_id
attribute.
43798 43799 43800 |
# File 'lib/ovirtsdk4/types.rb', line 43798 def domain_entry_id=(value) @domain_entry_id = value end |
#hash ⇒ Object
Generates a hash value for this object.
43988 43989 43990 43991 43992 43993 43994 43995 43996 |
# File 'lib/ovirtsdk4/types.rb', line 43988 def hash super + @domain.hash + @domain_entry_id.hash + @namespace.hash + @permissions.hash + @roles.hash + @tags.hash end |
#id ⇒ String
Returns the value of the id
attribute.
43807 43808 43809 |
# File 'lib/ovirtsdk4/types.rb', line 43807 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
43816 43817 43818 |
# File 'lib/ovirtsdk4/types.rb', line 43816 def id=(value) @id = value end |
#name ⇒ String
Returns the value of the name
attribute.
43825 43826 43827 |
# File 'lib/ovirtsdk4/types.rb', line 43825 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
43834 43835 43836 |
# File 'lib/ovirtsdk4/types.rb', line 43834 def name=(value) @name = value end |
#namespace ⇒ String
Returns the value of the namespace
attribute.
43843 43844 43845 |
# File 'lib/ovirtsdk4/types.rb', line 43843 def namespace @namespace end |
#namespace=(value) ⇒ Object
Sets the value of the namespace
attribute.
43852 43853 43854 |
# File 'lib/ovirtsdk4/types.rb', line 43852 def namespace=(value) @namespace = value end |
#permissions ⇒ Array<Permission>
Returns the value of the permissions
attribute.
43861 43862 43863 |
# File 'lib/ovirtsdk4/types.rb', line 43861 def @permissions end |
#permissions=(list) ⇒ Object
Sets the value of the permissions
attribute.
43870 43871 43872 43873 43874 43875 43876 43877 43878 43879 43880 |
# File 'lib/ovirtsdk4/types.rb', line 43870 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 @permissions = list end |
#roles ⇒ Array<Role>
Returns the value of the roles
attribute.
43887 43888 43889 |
# File 'lib/ovirtsdk4/types.rb', line 43887 def roles @roles end |
#roles=(list) ⇒ Object
Sets the value of the roles
attribute.
43896 43897 43898 43899 43900 43901 43902 43903 43904 43905 43906 |
# File 'lib/ovirtsdk4/types.rb', line 43896 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.
43913 43914 43915 |
# File 'lib/ovirtsdk4/types.rb', line 43913 def @tags end |
#tags=(list) ⇒ Object
Sets the value of the tags
attribute.
43922 43923 43924 43925 43926 43927 43928 43929 43930 43931 43932 |
# File 'lib/ovirtsdk4/types.rb', line 43922 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 @tags = list end |