Polishing
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2002-2015 the original author or authors.
|
||||
* Copyright 2002-2016 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -69,6 +69,23 @@ public class BeanDefinitionReaderUtils {
|
||||
return bd;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate a bean name for the given top-level bean definition,
|
||||
* unique within the given bean factory.
|
||||
* @param beanDefinition the bean definition to generate a bean name for
|
||||
* @param registry the bean factory that the definition is going to be
|
||||
* registered with (to check for existing bean names)
|
||||
* @return the generated bean name
|
||||
* @throws BeanDefinitionStoreException if no unique name can be generated
|
||||
* for the given bean definition
|
||||
* @see #generateBeanName(BeanDefinition, BeanDefinitionRegistry, boolean)
|
||||
*/
|
||||
public static String generateBeanName(BeanDefinition beanDefinition, BeanDefinitionRegistry registry)
|
||||
throws BeanDefinitionStoreException {
|
||||
|
||||
return generateBeanName(beanDefinition, registry, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate a bean name for the given bean definition, unique within the
|
||||
* given bean factory.
|
||||
@@ -117,22 +134,6 @@ public class BeanDefinitionReaderUtils {
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate a bean name for the given top-level bean definition,
|
||||
* unique within the given bean factory.
|
||||
* @param beanDefinition the bean definition to generate a bean name for
|
||||
* @param registry the bean factory that the definition is going to be
|
||||
* registered with (to check for existing bean names)
|
||||
* @return the generated bean name
|
||||
* @throws BeanDefinitionStoreException if no unique name can be generated
|
||||
* for the given bean definition
|
||||
*/
|
||||
public static String generateBeanName(BeanDefinition beanDefinition, BeanDefinitionRegistry registry)
|
||||
throws BeanDefinitionStoreException {
|
||||
|
||||
return generateBeanName(beanDefinition, registry, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Register the given bean definition with the given bean factory.
|
||||
* @param definitionHolder the bean definition including name and aliases
|
||||
|
||||
Reference in New Issue
Block a user