public class GenericGroovyXmlWebContextLoader extends GenericXmlWebContextLoader
AbstractGenericWebContextLoader
that loads
bean definitions from Groovy scripts and XML configuration files.
Default resource locations are detected using the suffixes
"-context.xml"
and "Context.groovy"
.
GroovyBeanDefinitionReader
,
GenericXmlWebContextLoader
,
AnnotationConfigWebContextLoader
logger
Constructor and Description |
---|
GenericGroovyXmlWebContextLoader() |
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
getResourceSuffix()
GenericGroovyXmlWebContextLoader supports both Groovy and XML
resource types for detection of defaults. |
protected java.lang.String[] |
getResourceSuffixes()
Returns
"-context.xml" and "Context.groovy" in order to
support detection of a default XML config file or Groovy script. |
protected void |
loadBeanDefinitions(GenericWebApplicationContext context,
WebMergedContextConfiguration webMergedConfig)
Loads bean definitions using a
GroovyBeanDefinitionReader . |
validateMergedContextConfiguration
configureWebResources, customizeBeanFactory, customizeContext, loadContext, loadContext
generateDefaultLocations, isGenerateDefaultLocations, modifyLocations, prepareContext, processContextConfiguration, processLocations
protected void loadBeanDefinitions(GenericWebApplicationContext context, WebMergedContextConfiguration webMergedConfig)
GroovyBeanDefinitionReader
.loadBeanDefinitions
in class GenericXmlWebContextLoader
context
- the context into which the bean definitions should be loadedwebMergedConfig
- the merged context configuration to use to load the
web application contextAbstractGenericWebContextLoader.loadBeanDefinitions(org.springframework.web.context.support.GenericWebApplicationContext, org.springframework.test.context.web.WebMergedContextConfiguration)
protected java.lang.String[] getResourceSuffixes()
"-context.xml" and "Context.groovy"
in order to
support detection of a default XML config file or Groovy script.getResourceSuffixes
in class AbstractContextLoader
null
or emptyAbstractContextLoader.generateDefaultLocations(Class)
protected java.lang.String getResourceSuffix()
GenericGroovyXmlWebContextLoader
supports both Groovy and XML
resource types for detection of defaults. Consequently, this method
is not supported.getResourceSuffix
in class GenericXmlWebContextLoader
null
or emptyjava.lang.UnsupportedOperationException
getResourceSuffixes()