Can be implemented by any service needing to be notified when the
NPMRegistry is updated.
Note that implementers of this interface must not depend on
NPMRegistry, since that would create circular references.
If, for some reason, you need to invoke
NPMRegistry from your
listener, the best way to obtain a reference to it is by using a
org.osgi.util.tracker.ServiceTracker and assuming that any data you
compute that depends on
NPMRegistry is optional, since it is possible
that, by the time you need to access it, the
NPMRegistry is not
available.
Another caveat: the
NPMRegistry invokes listeners whenever it goes
up and down, so you don't need to worry about that in your listener
implementation. However, if your listener goes down, then up, the
NPMRegistry won't invoke it, so it's your responsibility to handle
that situation, whether by simulating an update or doing anything you need to
make your data depending on
NPMRegistry available.