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.
10465 10466 10467 |
# File 'lib/ovirtsdk4/services.rb', line 10465 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.
10454 10455 10456 |
# File 'lib/ovirtsdk4/services.rb', line 10454 def list(opts = {}) internal_get(LIST, opts) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
10476 10477 10478 10479 10480 10481 10482 10483 10484 10485 |
# File 'lib/ovirtsdk4/services.rb', line 10476 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 |