|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jclouds.osgi.MetadataBundleListener
public class MetadataBundleListener
A BundleListener that listens for BundleEvent and searches for ProviderMetadata and ApiMetadata in newly
installed Bundles. This is used as a workaround for OSGi environments where the ServiceLoader cannot cross bundle
boundaries.
| Constructor Summary | |
|---|---|
MetadataBundleListener()
|
|
| Method Summary | |
|---|---|
void |
bundleChanged(org.osgi.framework.BundleEvent event)
|
ApiMetadata |
getApiMetadata(org.osgi.framework.Bundle bundle)
Creates an instance of ApiMetadata from the Bundle. |
String |
getApiMetadataClassName(org.osgi.framework.Bundle bundle)
Retrieves the ProviderMetadata class name for the bundle if it exists. |
String |
getMetadataClassName(org.osgi.framework.Bundle bundle,
String pathToMetadata)
|
ProviderMetadata |
getProviderMetadata(org.osgi.framework.Bundle bundle)
Creates an instance of ProviderMetadata from the Bundle. |
String |
getProviderMetadataClassName(org.osgi.framework.Bundle bundle)
Retrieves the ProviderMetadata class name for the bundle if it exists. |
void |
start(org.osgi.framework.BundleContext bundleContext)
|
void |
stop(org.osgi.framework.BundleContext bundleContext)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public MetadataBundleListener()
| Method Detail |
|---|
public void start(org.osgi.framework.BundleContext bundleContext)
public void stop(org.osgi.framework.BundleContext bundleContext)
public void bundleChanged(org.osgi.framework.BundleEvent event)
bundleChanged in interface org.osgi.framework.BundleListenerpublic ProviderMetadata getProviderMetadata(org.osgi.framework.Bundle bundle)
ProviderMetadata from the Bundle.
bundle -
public ApiMetadata getApiMetadata(org.osgi.framework.Bundle bundle)
ApiMetadata from the Bundle.
bundle -
public String getMetadataClassName(org.osgi.framework.Bundle bundle,
String pathToMetadata)
public String getProviderMetadataClassName(org.osgi.framework.Bundle bundle)
ProviderMetadata class name for the bundle if it exists.
bundle -
public String getApiMetadataClassName(org.osgi.framework.Bundle bundle)
ProviderMetadata class name for the bundle if it exists.
bundle -
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||