public final class SingleServiceTracker<T> extends Object implements org.osgi.framework.ServiceListener
Modifier and Type | Class and Description |
---|---|
static interface |
SingleServiceTracker.SingleServiceListener |
Constructor and Description |
---|
SingleServiceTracker(org.osgi.framework.BundleContext context,
Class<T> clazz,
SingleServiceTracker.SingleServiceListener sl) |
SingleServiceTracker(org.osgi.framework.BundleContext context,
Class<T> clazz,
String filterString,
SingleServiceTracker.SingleServiceListener sl) |
SingleServiceTracker(org.osgi.framework.BundleContext context,
String className,
String filterString,
SingleServiceTracker.SingleServiceListener sl) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
T |
getService() |
org.osgi.framework.ServiceReference<?> |
getServiceReference() |
void |
open() |
void |
serviceChanged(org.osgi.framework.ServiceEvent event) |
public SingleServiceTracker(org.osgi.framework.BundleContext context, Class<T> clazz, SingleServiceTracker.SingleServiceListener sl) throws org.osgi.framework.InvalidSyntaxException
org.osgi.framework.InvalidSyntaxException
public SingleServiceTracker(org.osgi.framework.BundleContext context, Class<T> clazz, String filterString, SingleServiceTracker.SingleServiceListener sl) throws org.osgi.framework.InvalidSyntaxException
org.osgi.framework.InvalidSyntaxException
public SingleServiceTracker(org.osgi.framework.BundleContext context, String className, String filterString, SingleServiceTracker.SingleServiceListener sl) throws org.osgi.framework.InvalidSyntaxException
org.osgi.framework.InvalidSyntaxException
public T getService()
public org.osgi.framework.ServiceReference<?> getServiceReference()
public void open()
public void serviceChanged(org.osgi.framework.ServiceEvent event)
serviceChanged
in interface org.osgi.framework.ServiceListener
public void close()
Copyright © 2006–2019 The Apache Software Foundation. All rights reserved.