public class UscServiceUtils extends Object
Constructor and Description |
---|
UscServiceUtils() |
Modifier and Type | Method and Description |
---|---|
static <S,B> S |
getService(Class<S> clazz)
Retrieve only first one Instance of a Service
|
static <S,B> List<S> |
getServices(Class<S> clazz,
B bundle,
String serviceFilter)
Retrieve all the Instances of a Service, optionally filtered via
serviceFilter if non-null else all the results are returned if null
|
static <S,B> boolean |
registerService(B bundle,
Class<S> clazz,
S service,
Dictionary<String,Object> properties)
Register a Service in the OSGi service registry
|
public static <S,B> boolean registerService(B bundle, Class<S> clazz, S service, Dictionary<String,Object> properties)
clazz
- The target classservice
- of the object exporting the serviceproperties
- The properties to be attached to the service registrationpublic static <S,B> S getService(Class<S> clazz)
clazz
- The target classpublic static <S,B> List<S> getServices(Class<S> clazz, B bundle, String serviceFilter)
clazz
- The target classbundle
- The callerserviceFilter
- LDAP filter to be applied in the searchCopyright © 2019 OpenDaylight. All rights reserved.