org.apache.camel.core.osgi
Class OsgiComponentResolver

java.lang.Object
  extended by org.apache.camel.core.osgi.OsgiComponentResolver
All Implemented Interfaces:
ComponentResolver
Direct Known Subclasses:
BlueprintComponentResolver

public class OsgiComponentResolver
extends Object
implements ComponentResolver


Constructor Summary
OsgiComponentResolver(org.osgi.framework.BundleContext bundleContext)
           
 
Method Summary
protected  Component getComponent(String name, CamelContext context)
           
 Component resolveComponent(String name, CamelContext context)
          Attempts to resolve the component for the given URI
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OsgiComponentResolver

public OsgiComponentResolver(org.osgi.framework.BundleContext bundleContext)
Method Detail

resolveComponent

public Component resolveComponent(String name,
                                  CamelContext context)
                           throws Exception
Description copied from interface: ComponentResolver
Attempts to resolve the component for the given URI

Specified by:
resolveComponent in interface ComponentResolver
Parameters:
name - the component name to resolve
context - the context to load the component if it can be resolved
Returns:
the component which is added to the context or null if it cannot be resolved
Throws:
Exception - is thrown if the the component could not be loaded

getComponent

protected Component getComponent(String name,
                                 CamelContext context)
                          throws Exception
Throws:
Exception


Copyright © 2007-2010 IONA Open Source Community. All Rights Reserved.