public class BeanDefinitionChecker extends Object
| Constructor and Description |
|---|
BeanDefinitionChecker() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
isCompatible(org.springframework.beans.factory.config.BeanDefinition newDefinition,
org.springframework.beans.factory.config.BeanDefinition existingDefinition)
copyPasta from spring-context:component-scan classes
Determine whether the given new bean definition is compatible with
the given existing bean definition.
|
static boolean |
needToRegister(String beanName,
org.springframework.beans.factory.config.BeanDefinition beanDefinition,
org.springframework.beans.factory.support.BeanDefinitionRegistry registry)
copyPasta from spring-context:component-scan classes
Check the given candidate's bean name, determining whether the corresponding
bean definition needs to be registered or conflicts with an existing definition.
|
public static boolean needToRegister(String beanName, org.springframework.beans.factory.config.BeanDefinition beanDefinition, org.springframework.beans.factory.support.BeanDefinitionRegistry registry) throws IllegalStateException
IllegalStateExceptionpublic static boolean isCompatible(org.springframework.beans.factory.config.BeanDefinition newDefinition,
org.springframework.beans.factory.config.BeanDefinition existingDefinition)
The default implementation simply considers them as compatible when the bean class name matches.
Copyright © 2019 Atlassian. All rights reserved.