Class: OvirtSDK4::GlusterHooksService
- Defined in:
- lib/ovirtsdk4/services.rb,
lib/ovirtsdk4/services.rb
Instance Method Summary collapse
-
#hook_service(id) ⇒ GlusterHookService
Locates the
hook
service. -
#list(opts = {}) ⇒ Array<GlusterHook>
Returns the list of hooks.
-
#service(path) ⇒ Service
Locates the service corresponding to the given path.
Methods inherited from Service
Instance Method Details
#hook_service(id) ⇒ GlusterHookService
Locates the hook
service.
11535 11536 11537 |
# File 'lib/ovirtsdk4/services.rb', line 11535 def hook_service(id) GlusterHookService.new(self, id) end |
#list(opts = {}) ⇒ Array<GlusterHook>
Returns the list of hooks.
The order of the returned list of hooks isn’t guaranteed.
11524 11525 11526 |
# File 'lib/ovirtsdk4/services.rb', line 11524 def list(opts = {}) internal_get(LIST, opts) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
11546 11547 11548 11549 11550 11551 11552 11553 11554 11555 |
# File 'lib/ovirtsdk4/services.rb', line 11546 def service(path) if path.nil? || path == '' return self end index = path.index('/') if index.nil? return hook_service(path) end return hook_service(path[0..(index - 1)]).service(path[(index + 1)..-1]) end |