当前位置: 首页>>代码示例>>Java>>正文


Java ProblemReporter类代码示例

本文整理汇总了Java中org.springframework.beans.factory.parsing.ProblemReporter的典型用法代码示例。如果您正苦于以下问题:Java ProblemReporter类的具体用法?Java ProblemReporter怎么用?Java ProblemReporter使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


ProblemReporter类属于org.springframework.beans.factory.parsing包,在下文中一共展示了ProblemReporter类的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: ConfigurationClassParser

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Create a new {@link ConfigurationClassParser} instance that will be used
 * to populate the set of configuration classes.
 */
public ConfigurationClassParser(MetadataReaderFactory metadataReaderFactory,
		ProblemReporter problemReporter, Environment environment, ResourceLoader resourceLoader,
		BeanNameGenerator componentScanBeanNameGenerator, BeanDefinitionRegistry registry) {

	this.metadataReaderFactory = metadataReaderFactory;
	this.problemReporter = problemReporter;
	this.environment = environment;
	this.resourceLoader = resourceLoader;
	this.registry = registry;
	this.componentScanParser = new ComponentScanAnnotationParser(
			resourceLoader, environment, componentScanBeanNameGenerator, registry);
	this.conditionEvaluator = new ConditionEvaluator(registry, environment, resourceLoader);
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:18,代码来源:ConfigurationClassParser.java

示例2: ConfigurationClassBeanDefinitionReader

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Create a new {@link ConfigurationClassBeanDefinitionReader} instance that will be used
 * to populate the given {@link BeanDefinitionRegistry}.
 */
public ConfigurationClassBeanDefinitionReader(BeanDefinitionRegistry registry, SourceExtractor sourceExtractor,
		ProblemReporter problemReporter, MetadataReaderFactory metadataReaderFactory,
		ResourceLoader resourceLoader, Environment environment, BeanNameGenerator importBeanNameGenerator) {

	this.registry = registry;
	this.sourceExtractor = sourceExtractor;
	this.problemReporter = problemReporter;
	this.metadataReaderFactory = metadataReaderFactory;
	this.resourceLoader = resourceLoader;
	this.environment = environment;
	this.importBeanNameGenerator = importBeanNameGenerator;
	this.conditionEvaluator = new ConditionEvaluator(registry, environment, resourceLoader);
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:18,代码来源:ConfigurationClassBeanDefinitionReader.java

示例3: validate

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
@Override
public void validate(ProblemReporter problemReporter) {
	if (getMetadata().isStatic()) {
		// static @Bean methods have no constraints to validate -> return immediately
		return;
	}

	if (this.configurationClass.getMetadata().isAnnotated(Configuration.class.getName())) {
		if (!getMetadata().isOverridable()) {
			// instance @Bean methods within @Configuration classes must be overridable to accommodate CGLIB
			problemReporter.error(new NonOverridableMethodError());
		}
	}
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:15,代码来源:BeanMethod.java

示例4: validate

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
public void validate(ProblemReporter problemReporter) {
	// A configuration class may not be final (CGLIB limitation)
	if (getMetadata().isAnnotated(Configuration.class.getName())) {
		if (getMetadata().isFinal()) {
			problemReporter.error(new FinalConfigurationProblem());
		}
	}

	for (BeanMethod beanMethod : this.beanMethods) {
		beanMethod.validate(problemReporter);
	}
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:13,代码来源:ConfigurationClass.java

示例5: XmlReaderContext

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
public XmlReaderContext(
		Resource resource, ProblemReporter problemReporter,
		ReaderEventListener eventListener, SourceExtractor sourceExtractor,
		XmlBeanDefinitionReader reader, NamespaceHandlerResolver namespaceHandlerResolver) {

	super(resource, problemReporter, eventListener, sourceExtractor);
	this.reader = reader;
	this.namespaceHandlerResolver = namespaceHandlerResolver;
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:10,代码来源:XmlReaderContext.java

示例6: ConfigurationClassParser

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Create a new {@link ConfigurationClassParser} instance that will be used
 * to populate the set of configuration classes.
 */
public ConfigurationClassParser(MetadataReaderFactory metadataReaderFactory,
		ProblemReporter problemReporter, Environment environment, ResourceLoader resourceLoader,
		BeanNameGenerator componentScanBeanNameGenerator, BeanDefinitionRegistry registry) {

	this.metadataReaderFactory = metadataReaderFactory;
	this.problemReporter = problemReporter;
	this.environment = environment;
	this.resourceLoader = resourceLoader;
	this.registry = registry;
	this.componentScanParser = new ComponentScanAnnotationParser(
			resourceLoader, environment, componentScanBeanNameGenerator, registry);
}
 
开发者ID:lindzh,项目名称:mybatis-spring-1.2.2,代码行数:17,代码来源:ConfigurationClassParser.java

示例7: ConfigurationClassBeanDefinitionReader

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Create a new {@link ConfigurationClassBeanDefinitionReader} instance that will be used
 * to populate the given {@link BeanDefinitionRegistry}.
 */
public ConfigurationClassBeanDefinitionReader(
		BeanDefinitionRegistry registry, SourceExtractor sourceExtractor,
		ProblemReporter problemReporter, MetadataReaderFactory metadataReaderFactory,
		ResourceLoader resourceLoader, Environment environment, BeanNameGenerator importBeanNameGenerator) {

	this.registry = registry;
	this.sourceExtractor = sourceExtractor;
	this.problemReporter = problemReporter;
	this.metadataReaderFactory = metadataReaderFactory;
	this.resourceLoader = resourceLoader;
	this.environment = environment;
	this.importBeanNameGenerator = importBeanNameGenerator;
}
 
开发者ID:deathspeeder,项目名称:class-guard,代码行数:18,代码来源:ConfigurationClassBeanDefinitionReader.java

示例8: ConfigurationClassBeanDefinitionReader

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Create a new {@link ConfigurationClassBeanDefinitionReader} instance that will be used to populate the given
 * {@link BeanDefinitionRegistry}.
 */
public ConfigurationClassBeanDefinitionReader(final BeanDefinitionRegistry registry, final SourceExtractor sourceExtractor,
    final ProblemReporter problemReporter, final MetadataReaderFactory metadataReaderFactory, final ResourceLoader resourceLoader,
    final Environment environment, final BeanNameGenerator importBeanNameGenerator) {

  this.registry = registry;
  this.sourceExtractor = sourceExtractor;
  this.problemReporter = problemReporter;
  this.metadataReaderFactory = metadataReaderFactory;
  this.resourceLoader = resourceLoader;
  this.environment = environment;
  this.importBeanNameGenerator = importBeanNameGenerator;
}
 
开发者ID:ahoehma,项目名称:spring-autowire-qualified-beans,代码行数:17,代码来源:ConfigurationClassBeanDefinitionReader.java

示例9: validate

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
public void validate(ProblemReporter problemReporter) {
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:3,代码来源:ConfigurationMethod.java

示例10: setProblemReporter

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Set the {@link ProblemReporter} to use.
 * <p>Used to register any problems detected with {@link Configuration} or {@link Bean}
 * declarations. For instance, an @Bean method marked as {@code final} is illegal
 * and would be reported as a problem. Defaults to {@link FailFastProblemReporter}.
 */
public void setProblemReporter(ProblemReporter problemReporter) {
	this.problemReporter = (problemReporter != null ? problemReporter : new FailFastProblemReporter());
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:10,代码来源:ConfigurationClassPostProcessor.java

示例11: setProblemReporter

import org.springframework.beans.factory.parsing.ProblemReporter; //导入依赖的package包/类
/**
 * Specify which {@link org.springframework.beans.factory.parsing.ProblemReporter} to use.
 * <p>The default implementation is {@link org.springframework.beans.factory.parsing.FailFastProblemReporter}
 * which exhibits fail fast behaviour. External tools can provide an alternative implementation
 * that collates errors and warnings for display in the tool UI.
 */
public void setProblemReporter(ProblemReporter problemReporter) {
	this.problemReporter = (problemReporter != null ? problemReporter : new FailFastProblemReporter());
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:10,代码来源:XmlBeanDefinitionReader.java


注:本文中的org.springframework.beans.factory.parsing.ProblemReporter类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。