Class: OvirtSDK4::HostHooksService
- Defined in:
- lib/ovirtsdk4/services.rb,
lib/ovirtsdk4/services.rb
Instance Method Summary collapse
-
#hook_service(id) ⇒ HostHookService
Locates the
hook
service. -
#list(opts = {}) ⇒ Array<Hook>
Returns the list of hooks configured for the host.
-
#service(path) ⇒ Service
Locates the service corresponding to the given path.
Methods inherited from Service
Instance Method Details
#hook_service(id) ⇒ HostHookService
Locates the hook
service.
12358 12359 12360 |
# File 'lib/ovirtsdk4/services.rb', line 12358 def hook_service(id) HostHookService.new(self, id) end |
#list(opts = {}) ⇒ Array<Hook>
Returns the list of hooks configured for the host.
The order of the returned list of hooks is random.
12347 12348 12349 |
# File 'lib/ovirtsdk4/services.rb', line 12347 def list(opts = {}) internal_get(LIST, opts) end |
#service(path) ⇒ Service
Locates the service corresponding to the given path.
12369 12370 12371 12372 12373 12374 12375 12376 12377 12378 |
# File 'lib/ovirtsdk4/services.rb', line 12369 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 |