类 GenericPropertiesContextLoader
- java.lang.Object
- org.springframework.test.context.support.AbstractContextLoader
- org.springframework.test.context.support.AbstractGenericContextLoader
- org.springframework.test.context.support.GenericPropertiesContextLoader
- 所有已实现的接口:
ContextLoader,SmartContextLoader
public class GenericPropertiesContextLoader extends AbstractGenericContextLoader
Concrete implementation ofAbstractGenericContextLoaderthat reads bean definitions from JavaPropertiesresources.- 从以下版本开始:
- 2.5
- 作者:
- Sam Brannen
字段概要
从类继承的字段 org.springframework.test.context.support.AbstractGenericContextLoader
logger
构造器概要
构造器 构造器 说明 GenericPropertiesContextLoader()
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 protected BeanDefinitionReadercreateBeanDefinitionReader(GenericApplicationContext context)Creates a newPropertiesBeanDefinitionReader.protected StringgetResourceSuffix()Returns "-context.properties".protected voidvalidateMergedContextConfiguration(MergedContextConfiguration mergedConfig)Ensure that the suppliedMergedContextConfigurationdoes not containclasses.从类继承的方法 org.springframework.test.context.support.AbstractGenericContextLoader
createContext, customizeBeanFactory, customizeContext, loadBeanDefinitions, loadContext, loadContext, prepareContext
从类继承的方法 org.springframework.test.context.support.AbstractContextLoader
customizeContext, generateDefaultLocations, getResourceSuffixes, isGenerateDefaultLocations, modifyLocations, prepareContext, processContextConfiguration, processLocations
构造器详细资料
GenericPropertiesContextLoader
public GenericPropertiesContextLoader()
方法详细资料
createBeanDefinitionReader
protected BeanDefinitionReader createBeanDefinitionReader(GenericApplicationContext context)
Creates a newPropertiesBeanDefinitionReader.- 指定者:
createBeanDefinitionReader在类中AbstractGenericContextLoader- 参数:
context- the context for which theBeanDefinitionReadershould be created- 返回:
- a new PropertiesBeanDefinitionReader
- 另请参阅:
PropertiesBeanDefinitionReader
getResourceSuffix
protected String getResourceSuffix()
Returns "-context.properties".- 指定者:
getResourceSuffix在类中AbstractContextLoader- 返回:
- the resource suffix; never
nullor empty - 另请参阅:
AbstractContextLoader.generateDefaultLocations(Class),AbstractContextLoader.getResourceSuffixes()
validateMergedContextConfiguration
protected void validateMergedContextConfiguration(MergedContextConfiguration mergedConfig)
Ensure that the suppliedMergedContextConfigurationdoes not containclasses.- 覆盖:
validateMergedContextConfiguration在类中AbstractGenericContextLoader- 参数:
mergedConfig- the merged configuration to validate- 从以下版本开始:
- 4.0.4
- 另请参阅:
AbstractGenericContextLoader.validateMergedContextConfiguration(org.springframework.test.context.MergedContextConfiguration)