org.apache.camel.test.blueprint
Class CamelBlueprintHelper

java.lang.Object
  extended by org.apache.camel.test.blueprint.CamelBlueprintHelper

public final class CamelBlueprintHelper
extends Object

Helper for using Blueprint with Camel.


Field Summary
static String BUNDLE_FILTER
           
static String BUNDLE_VERSION
           
static long DEFAULT_TIMEOUT
           
 
Method Summary
static org.osgi.framework.BundleContext createBundleContext(String name, String descriptors, boolean includeTestBundle)
           
static org.osgi.framework.BundleContext createBundleContext(String name, String descriptors, boolean includeTestBundle, String bundleFilter, String testBundleVersion)
           
static org.osgi.framework.BundleContext createBundleContext(String name, String descriptors, boolean includeTestBundle, String bundleFilter, String testBundleVersion, String testBundleDirectives)
           
static org.osgi.framework.BundleContext createBundleContext(String name, String bundleFilter, org.ops4j.pax.swissbox.tinybundles.core.TinyBundle bundle)
           
protected static org.ops4j.pax.swissbox.tinybundles.core.TinyBundle createTestBundle(String name, String version, String descriptors)
           
static void disposeBundleContext(org.osgi.framework.BundleContext bundleContext)
           
static
<T> T
getOsgiService(org.osgi.framework.BundleContext bundleContext, Class<T> type)
           
static
<T> T
getOsgiService(org.osgi.framework.BundleContext bundleContext, Class<T> type, long timeout)
           
static
<T> T
getOsgiService(org.osgi.framework.BundleContext bundleContext, Class<T> type, String filter)
           
static
<T> T
getOsgiService(org.osgi.framework.BundleContext bundleContext, Class<T> type, String filter, long timeout)
           
static void setPersistentFileForConfigAdmin(org.osgi.framework.BundleContext bundleContext, String pid, String fileName, Dictionary props)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_TIMEOUT

public static final long DEFAULT_TIMEOUT
See Also:
Constant Field Values

BUNDLE_FILTER

public static final String BUNDLE_FILTER
See Also:
Constant Field Values

BUNDLE_VERSION

public static final String BUNDLE_VERSION
See Also:
Constant Field Values
Method Detail

createBundleContext

public static org.osgi.framework.BundleContext createBundleContext(String name,
                                                                   String descriptors,
                                                                   boolean includeTestBundle)
                                                            throws Exception
Throws:
Exception

createBundleContext

public static org.osgi.framework.BundleContext createBundleContext(String name,
                                                                   String descriptors,
                                                                   boolean includeTestBundle,
                                                                   String bundleFilter,
                                                                   String testBundleVersion)
                                                            throws Exception
Throws:
Exception

createBundleContext

public static org.osgi.framework.BundleContext createBundleContext(String name,
                                                                   String descriptors,
                                                                   boolean includeTestBundle,
                                                                   String bundleFilter,
                                                                   String testBundleVersion,
                                                                   String testBundleDirectives)
                                                            throws Exception
Throws:
Exception

createBundleContext

public static org.osgi.framework.BundleContext createBundleContext(String name,
                                                                   String bundleFilter,
                                                                   org.ops4j.pax.swissbox.tinybundles.core.TinyBundle bundle)
                                                            throws Exception
Throws:
Exception

disposeBundleContext

public static void disposeBundleContext(org.osgi.framework.BundleContext bundleContext)
                                 throws org.osgi.framework.BundleException
Throws:
org.osgi.framework.BundleException

setPersistentFileForConfigAdmin

public static void setPersistentFileForConfigAdmin(org.osgi.framework.BundleContext bundleContext,
                                                   String pid,
                                                   String fileName,
                                                   Dictionary props)
                                            throws IOException
Throws:
IOException

getOsgiService

public static <T> T getOsgiService(org.osgi.framework.BundleContext bundleContext,
                                   Class<T> type,
                                   long timeout)

getOsgiService

public static <T> T getOsgiService(org.osgi.framework.BundleContext bundleContext,
                                   Class<T> type)

getOsgiService

public static <T> T getOsgiService(org.osgi.framework.BundleContext bundleContext,
                                   Class<T> type,
                                   String filter)

getOsgiService

public static <T> T getOsgiService(org.osgi.framework.BundleContext bundleContext,
                                   Class<T> type,
                                   String filter,
                                   long timeout)

createTestBundle

protected static org.ops4j.pax.swissbox.tinybundles.core.TinyBundle createTestBundle(String name,
                                                                                     String version,
                                                                                     String descriptors)
                                                                              throws FileNotFoundException,
                                                                                     MalformedURLException
Throws:
FileNotFoundException
MalformedURLException


Apache Camel