Dependency
Dependency
Returns the first available service of the specified class which satisfies the filter if available.
Returns the first available service of the specified class which satisfies the filter if available. If the service
is not available, it returns None
. The service is not explicitly released.
service type
filter expression
service if available
Returns the highest-ranked service of the specified type if available.
Returns the highest-ranked service of the specified type if available. The service is not explicitly released. It's assumed that the service will be used until the bundle stops. Doesn't take type parameters into account!
service type
service if available
Like service with filter but returns the service reference.
Like service with filter but returns the service reference.
Like service but returns the reference so you can access meta information about that service.
Like service but returns the reference so you can access meta information about that service.
An implicit conversion adds a service
property to the reference, so you can simply use that to obtain the service.
Doesn't take type parameters into account!
Converts a service reference to a rich service reference so one can easily obtain the
corresponding service by calling service
, for example.
Converts a service reference to a rich service reference so one can easily obtain the
corresponding service by calling service
, for example.
Like services with filters but returns the references.
Like services with filters but returns the references.
Like services but returns service references.
Like services but returns service references.
Returns all services of the specified type which satisfy the given filter.
Returns all services of the specified type which satisfy the given filter.
service type
filter expression
services
Returns all services of the given type.
Executes the given handler with the first available service of the specified class which satisfies the filter if available.
Executes the given handler with the first available service of the specified class which satisfies the filter
if available. If it's not available, it still executes it but with None
.
When the handler returns, the service is released using org.osgi.framework.BundleContext#ungetService.
service type
function result type
filter expression
handler that uses the service
handler result
Executes the given handler with the highest-ranked service of the specified type.
Executes the given handler with the highest-ranked service of the specified type. If it's not available,
it still executes it but with None
. Doesn't take type parameters into account!
When the handler returns, the service is released using org.osgi.framework.BundleContext#ungetService.
service type
function result type
handler that uses the service
handler result
Methods for obtaining access to OSGi service references
Methods for obtaining access to OSGi services
A class that mixes in the ServiceConsuming trait. Use this if you want to use a class instead of a trait.