Class DefaultBootstrapContext
- java.lang.Object
- org.springframework.test.context.support.DefaultBootstrapContext
- All Implemented Interfaces:
BootstrapContext
public class DefaultBootstrapContext extends Object implements BootstrapContext
Default implementation of theBootstrapContextinterface.- Since:
- 4.1
- Author:
- Sam Brannen
Constructor Summary
Constructors Constructor Description DefaultBootstrapContext(Class<?> testClass, CacheAwareContextLoaderDelegate cacheAwareContextLoaderDelegate)Construct a newDefaultBootstrapContextfrom the supplied arguments.
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description CacheAwareContextLoaderDelegategetCacheAwareContextLoaderDelegate()Get theCacheAwareContextLoaderDelegateto use for transparent interaction with theContextCache.Class<?>getTestClass()Get the test class for this bootstrap context.StringtoString()Provide a String representation of this bootstrap context's state.
Constructor Detail
DefaultBootstrapContext
public DefaultBootstrapContext(Class<?> testClass, CacheAwareContextLoaderDelegate cacheAwareContextLoaderDelegate)
Construct a newDefaultBootstrapContextfrom the supplied arguments.- Parameters:
testClass- the test class for this bootstrap context; nevernullcacheAwareContextLoaderDelegate- the context loader delegate to use for transparent interaction with theContextCache; nevernull
Method Detail
getTestClass
public Class<?> getTestClass()
Get the test class for this bootstrap context.- Specified by:
getTestClassin interfaceBootstrapContext- Returns:
- the test class (never
null)
getCacheAwareContextLoaderDelegate
public CacheAwareContextLoaderDelegate getCacheAwareContextLoaderDelegate()
Get theCacheAwareContextLoaderDelegateto use for transparent interaction with theContextCache.- Specified by:
getCacheAwareContextLoaderDelegatein interfaceBootstrapContext- Returns:
- the context loader delegate (never
null)