Class: OvirtSDK4::GroupService
- Defined in:
- lib/ovirtsdk4/services.rb,
lib/ovirtsdk4/services.rb
Instance Method Summary collapse
-
#get(opts = {}) ⇒ Group
Gets the system group information.
-
#permissions_service ⇒ AssignedPermissionsService
Reference to the service that manages the collection of permissions assigned to this system group.
-
#remove(opts = {}) ⇒ Object
Removes the system group.
-
#roles_service ⇒ AssignedRolesService
Reference to the service that manages the collection of roles assigned to this system group.
-
#service(path) ⇒ Service
Locates the service corresponding to the given path.
-
#tags_service ⇒ AssignedTagsService
Reference to the service that manages the collection of tags assigned to this system group.
Methods inherited from Service
Instance Method Details
#get(opts = {}) ⇒ Group
Gets the system group information.
Usage:
GET /ovirt-engine/api/groups/123
Will return the group information:
<group href="/ovirt-engine/api/groups/123" id="123">
<name>mygroup</name>
<link href="/ovirt-engine/api/groups/123/roles" rel="roles"/>
<link href="/ovirt-engine/api/groups/123/permissions" rel="permissions"/>
<link href="/ovirt-engine/api/groups/123/tags" rel="tags"/>
<domain_entry_id>476652557A382F67696B6D2B32762B37796E46476D513D3D</domain_entry_id>
<namespace>DC=example,DC=com</namespace>
<domain href="/ovirt-engine/api/domains/ABCDEF" id="ABCDEF">
<name>myextension-authz</name>
</domain>
</group>
10726 10727 10728 |
# File 'lib/ovirtsdk4/services.rb', line 10726 def get(opts = {}) internal_get(GET, opts) end |
#permissions_service ⇒ AssignedPermissionsService
Reference to the service that manages the collection of permissions assigned to this system group.
10766 10767 10768 |
# File 'lib/ovirtsdk4/services.rb', line 10766 def @permissions_service ||= AssignedPermissionsService.new(self, 'permissions') end |
#remove(opts = {}) ⇒ Object
Removes the system group.
Usage:
DELETE /ovirt-engine/api/groups/123
10757 10758 10759 |
# File 'lib/ovirtsdk4/services.rb', line 10757 def remove(opts = {}) internal_remove(REMOVE, opts) end |
#roles_service ⇒ AssignedRolesService
Reference to the service that manages the collection of roles assigned to this system group.
10775 10776 10777 |
# File 'lib/ovirtsdk4/services.rb', line 10775 def roles_service @roles_service ||= AssignedRolesService.new(self, 'roles') end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
10795 10796 10797 10798 10799 10800 10801 10802 10803 10804 10805 10806 10807 10808 10809 10810 10811 10812 10813 10814 10815 10816 10817 10818 |
# File 'lib/ovirtsdk4/services.rb', line 10795 def service(path) if path.nil? || path == '' return self end if path == 'permissions' return end if path.start_with?('permissions/') return .service(path[12..-1]) end if path == 'roles' return roles_service end if path.start_with?('roles/') return roles_service.service(path[6..-1]) end if path == 'tags' return end if path.start_with?('tags/') return .service(path[5..-1]) end raise Error.new("The path \"#{path}\" doesn't correspond to any service") end |
#tags_service ⇒ AssignedTagsService
Reference to the service that manages the collection of tags assigned to this system group.
10784 10785 10786 |
# File 'lib/ovirtsdk4/services.rb', line 10784 def @tags_service ||= AssignedTagsService.new(self, 'tags') end |