Class: OvirtSDK4::Permission
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::Permission
- 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. -
#cluster ⇒ Cluster
Returns the value of the
cluster
attribute. -
#cluster=(value) ⇒ Object
Sets the value of the
cluster
attribute. -
#comment ⇒ String
Returns the value of the
comment
attribute. -
#comment=(value) ⇒ Object
Sets the value of the
comment
attribute. -
#data_center ⇒ DataCenter
Returns the value of the
data_center
attribute. -
#data_center=(value) ⇒ Object
Sets the value of the
data_center
attribute. -
#description ⇒ String
Returns the value of the
description
attribute. -
#description=(value) ⇒ Object
Sets the value of the
description
attribute. -
#disk ⇒ Disk
Returns the value of the
disk
attribute. -
#disk=(value) ⇒ Object
Sets the value of the
disk
attribute. -
#group ⇒ Group
Returns the value of the
group
attribute. -
#group=(value) ⇒ Object
Sets the value of the
group
attribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#host ⇒ Host
Returns the value of the
host
attribute. -
#host=(value) ⇒ Object
Sets the value of the
host
attribute. -
#id ⇒ String
Returns the value of the
id
attribute. -
#id=(value) ⇒ Object
Sets the value of the
id
attribute. -
#initialize(opts = {}) ⇒ Permission
constructor
Creates a new instance of the Permission class.
-
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#role ⇒ Role
Returns the value of the
role
attribute. -
#role=(value) ⇒ Object
Sets the value of the
role
attribute. -
#storage_domain ⇒ StorageDomain
Returns the value of the
storage_domain
attribute. -
#storage_domain=(value) ⇒ Object
Sets the value of the
storage_domain
attribute. -
#template ⇒ Template
Returns the value of the
template
attribute. -
#template=(value) ⇒ Object
Sets the value of the
template
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. -
#vm_pool ⇒ VmPool
Returns the value of the
vm_pool
attribute. -
#vm_pool=(value) ⇒ Object
Sets the value of the
vm_pool
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ Permission
Creates a new instance of the OvirtSDK4::Permission class.
13989 13990 13991 13992 13993 13994 13995 13996 13997 13998 13999 14000 14001 14002 |
# File 'lib/ovirtsdk4/types.rb', line 13989 def initialize(opts = {}) super(opts) self.cluster = opts[:cluster] self.data_center = opts[:data_center] self.disk = opts[:disk] self.group = opts[:group] self.host = opts[:host] self.role = opts[:role] self.storage_domain = opts[:storage_domain] self.template = opts[:template] self.user = opts[:user] self.vm = opts[:vm] self.vm_pool = opts[:vm_pool] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
14007 14008 14009 14010 14011 14012 14013 14014 14015 14016 14017 14018 14019 14020 |
# File 'lib/ovirtsdk4/types.rb', line 14007 def ==(other) super && @cluster == other.cluster && @data_center == other.data_center && @disk == other.disk && @group == other.group && @host == other.host && @role == other.role && @storage_domain == other.storage_domain && @template == other.template && @user == other.user && @vm == other.vm && @vm_pool == other.vm_pool end |
#cluster ⇒ Cluster
Returns the value of the cluster
attribute.
13609 13610 13611 |
# File 'lib/ovirtsdk4/types.rb', line 13609 def cluster @cluster end |
#cluster=(value) ⇒ Object
Sets the value of the cluster
attribute.
The value
parameter can be an instance of Cluster 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.
13622 13623 13624 13625 13626 13627 |
# File 'lib/ovirtsdk4/types.rb', line 13622 def cluster=(value) if value.is_a?(Hash) value = Cluster.new(value) end @cluster = value end |
#comment ⇒ String
Returns the value of the comment
attribute.
13634 13635 13636 |
# File 'lib/ovirtsdk4/types.rb', line 13634 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
13643 13644 13645 |
# File 'lib/ovirtsdk4/types.rb', line 13643 def comment=(value) @comment = value end |
#data_center ⇒ DataCenter
Returns the value of the data_center
attribute.
13652 13653 13654 |
# File 'lib/ovirtsdk4/types.rb', line 13652 def data_center @data_center end |
#data_center=(value) ⇒ Object
Sets the value of the data_center
attribute.
The value
parameter can be an instance of DataCenter 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.
13665 13666 13667 13668 13669 13670 |
# File 'lib/ovirtsdk4/types.rb', line 13665 def data_center=(value) if value.is_a?(Hash) value = DataCenter.new(value) end @data_center = value end |
#description ⇒ String
Returns the value of the description
attribute.
13677 13678 13679 |
# File 'lib/ovirtsdk4/types.rb', line 13677 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
13686 13687 13688 |
# File 'lib/ovirtsdk4/types.rb', line 13686 def description=(value) @description = value end |
#disk ⇒ Disk
Returns the value of the disk
attribute.
13695 13696 13697 |
# File 'lib/ovirtsdk4/types.rb', line 13695 def disk @disk end |
#disk=(value) ⇒ Object
Sets the value of the disk
attribute.
The value
parameter can be an instance of Disk 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.
13708 13709 13710 13711 13712 13713 |
# File 'lib/ovirtsdk4/types.rb', line 13708 def disk=(value) if value.is_a?(Hash) value = Disk.new(value) end @disk = value end |
#group ⇒ Group
Returns the value of the group
attribute.
13720 13721 13722 |
# File 'lib/ovirtsdk4/types.rb', line 13720 def group @group end |
#group=(value) ⇒ Object
Sets the value of the group
attribute.
The value
parameter can be an instance of Group 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.
13733 13734 13735 13736 13737 13738 |
# File 'lib/ovirtsdk4/types.rb', line 13733 def group=(value) if value.is_a?(Hash) value = Group.new(value) end @group = value end |
#hash ⇒ Object
Generates a hash value for this object.
14025 14026 14027 14028 14029 14030 14031 14032 14033 14034 14035 14036 14037 14038 |
# File 'lib/ovirtsdk4/types.rb', line 14025 def hash super + @cluster.hash + @data_center.hash + @disk.hash + @group.hash + @host.hash + @role.hash + @storage_domain.hash + @template.hash + @user.hash + @vm.hash + @vm_pool.hash end |
#host ⇒ Host
Returns the value of the host
attribute.
13745 13746 13747 |
# File 'lib/ovirtsdk4/types.rb', line 13745 def host @host end |
#host=(value) ⇒ Object
Sets the value of the host
attribute.
The value
parameter can be an instance of Host 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.
13758 13759 13760 13761 13762 13763 |
# File 'lib/ovirtsdk4/types.rb', line 13758 def host=(value) if value.is_a?(Hash) value = Host.new(value) end @host = value end |
#id ⇒ String
Returns the value of the id
attribute.
13770 13771 13772 |
# File 'lib/ovirtsdk4/types.rb', line 13770 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
13779 13780 13781 |
# File 'lib/ovirtsdk4/types.rb', line 13779 def id=(value) @id = value end |
#name ⇒ String
Returns the value of the name
attribute.
13788 13789 13790 |
# File 'lib/ovirtsdk4/types.rb', line 13788 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
13797 13798 13799 |
# File 'lib/ovirtsdk4/types.rb', line 13797 def name=(value) @name = value end |
#role ⇒ Role
Returns the value of the role
attribute.
13806 13807 13808 |
# File 'lib/ovirtsdk4/types.rb', line 13806 def role @role end |
#role=(value) ⇒ Object
Sets the value of the role
attribute.
The value
parameter can be an instance of Role 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.
13819 13820 13821 13822 13823 13824 |
# File 'lib/ovirtsdk4/types.rb', line 13819 def role=(value) if value.is_a?(Hash) value = Role.new(value) end @role = value end |
#storage_domain ⇒ StorageDomain
Returns the value of the storage_domain
attribute.
13831 13832 13833 |
# File 'lib/ovirtsdk4/types.rb', line 13831 def storage_domain @storage_domain end |
#storage_domain=(value) ⇒ Object
Sets the value of the storage_domain
attribute.
The value
parameter can be an instance of StorageDomain 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.
13844 13845 13846 13847 13848 13849 |
# File 'lib/ovirtsdk4/types.rb', line 13844 def storage_domain=(value) if value.is_a?(Hash) value = StorageDomain.new(value) end @storage_domain = value end |
#template ⇒ Template
Returns the value of the template
attribute.
13856 13857 13858 |
# File 'lib/ovirtsdk4/types.rb', line 13856 def template @template end |
#template=(value) ⇒ Object
Sets the value of the template
attribute.
The value
parameter can be an instance of Template 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.
13869 13870 13871 13872 13873 13874 |
# File 'lib/ovirtsdk4/types.rb', line 13869 def template=(value) if value.is_a?(Hash) value = Template.new(value) end @template = value end |
#user ⇒ User
Returns the value of the user
attribute.
13881 13882 13883 |
# File 'lib/ovirtsdk4/types.rb', line 13881 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.
13894 13895 13896 13897 13898 13899 |
# File 'lib/ovirtsdk4/types.rb', line 13894 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.
13906 13907 13908 |
# File 'lib/ovirtsdk4/types.rb', line 13906 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.
13919 13920 13921 13922 13923 13924 |
# File 'lib/ovirtsdk4/types.rb', line 13919 def vm=(value) if value.is_a?(Hash) value = Vm.new(value) end @vm = value end |
#vm_pool ⇒ VmPool
Returns the value of the vm_pool
attribute.
13931 13932 13933 |
# File 'lib/ovirtsdk4/types.rb', line 13931 def vm_pool @vm_pool end |
#vm_pool=(value) ⇒ Object
Sets the value of the vm_pool
attribute.
The value
parameter can be an instance of VmPool 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.
13944 13945 13946 13947 13948 13949 |
# File 'lib/ovirtsdk4/types.rb', line 13944 def vm_pool=(value) if value.is_a?(Hash) value = VmPool.new(value) end @vm_pool = value end |