public final class CamelSpringTestHelper extends Object
Note that this class makes use of ThreadLocal
s to maintain some state. It is imperative
that the state setters and getters are accessed within the scope of a single thread in order
for this class to work right.
Modifier and Type | Class and Description |
---|---|
static interface |
CamelSpringTestHelper.DoToSpringCamelContextsStrategy |
Modifier and Type | Method and Description |
---|---|
static void |
doToSpringCamelContexts(org.springframework.context.ApplicationContext context,
CamelSpringTestHelper.DoToSpringCamelContextsStrategy strategy)
Executes
strategy against all SpringCamelContext s found in the Spring context. |
static Collection<Method> |
getAllMethods(Class<?> clazz)
Returns all methods defined in
clazz and its superclasses/interfaces. |
static String |
getOriginalJmxDisabled() |
static Class<?> |
getTestClass() |
static void |
setOriginalJmxDisabledValue(String originalValue) |
static void |
setTestClass(Class<?> testClass) |
public static String getOriginalJmxDisabled()
public static void setOriginalJmxDisabledValue(String originalValue)
public static Class<?> getTestClass()
public static void setTestClass(Class<?> testClass)
public static Collection<Method> getAllMethods(Class<?> clazz)
clazz
and its superclasses/interfaces.public static void doToSpringCamelContexts(org.springframework.context.ApplicationContext context, CamelSpringTestHelper.DoToSpringCamelContextsStrategy strategy) throws Exception
strategy
against all SpringCamelContext
s found in the Spring context.
This method reduces the amount of repeated find and loop code throughout this class.context
- the Spring context to searchstrategy
- the strategy to execute against the found SpringCamelContext
sException
- if there is an error executing any of the strategiesCopyright © 2007–2016 The Apache Software Foundation. All rights reserved.