ServiceTracker in OSGi r4.1

Posted by Schildmeijer on Stack Overflow See other posts from Stack Overflow or by Schildmeijer
Published on 2009-03-17T14:02:42Z Indexed on 2010/03/28 17:23 UTC
Read the original article Hit count: 433

Filed under:
|

Im using a org.osgi.util.tracker.ServiceTracker (PrintableServiceTracker implements ServiceTrackerCustomizer and simply prints when a new service is added).

Filter filter = bc.createFilter("(objectClass=se.enea.print.Printable)");
        	tracker = new ServiceTracker(bc, filter, new PrintableServiceTracker(bc));

I've read about "pseudo registration" in the new ebook "OSGi in action" and I wonder if I have to do pseudo registration explicitly or if the framwork handles this automatically?

(Will already installed Printable services be caught by the ServiceTracker. will ServiceTracker.addingService(ServiceReference) be called for each of the pre installed Printable services)

© Stack Overflow or respective owner

Related posts about osgi

Related posts about felix