Operates on an AbstractBeanFactory and a plain
org. object.
Used by AbstractAutowireCapableBeanFactory.
AbstractAutowireCapableBeanFactory
| Modifier and Type | Class and Description |
|---|---|
| private static class | BeanDefinitionValueResolver.KeyedArgName
Holder class used for delayed toString building. |
| Modifier and Type | Field and Description |
|---|---|
| private final BeanDefinition | |
| private final AbstractAutowireCapableBeanFactory | |
| private final String | |
| private final TypeConverter |
| Access | Constructor and Description |
|---|---|
| public | BeanDefinitionValueResolver(AbstractAutowireCapableBeanFactory
the BeanFactory to resolve against beanFactory, String the name of the bean that we work on beanName, BeanDefinition the BeanDefinition of the bean that we work on beanDefinition, TypeConverter the TypeConverter to use for resolving TypedStringValues typeConverter)Create a BeanDefinitionValueResolver for the given BeanFactory and BeanDefinition,
using the given |
| public | BeanDefinitionValueResolver(AbstractAutowireCapableBeanFactory
the BeanFactory to resolve against beanFactory, String the name of the bean that we work on beanName, BeanDefinition the BeanDefinition of the bean that we work on beanDefinition)Create a BeanDefinitionValueResolver for the given BeanFactory and BeanDefinition
using a default |
| Modifier and Type | Method and Description |
|---|---|
| private String | Returns: the adapted name for the inner beanthe original name for the inner bean innerBeanName)Checks the given bean name whether it is unique. |
| private Object | Returns: the resolved value if necessary, or the original String valuethe original value (may be an expression) value)Evaluate the given String value as an expression, if necessary. |
| protected Object | Returns: the resolved valuethe candidate value (may be an expression) value)Evaluate the given value as an expression, if necessary. |
| protected Object | |
| public < the type of the resolution T> T | Returns: a resolved inner bean, as a result of applying theresolverthe inner bean name (or innerBeanName, BeanDefinition null to assign one)the inner raw bean definition innerBd, BiFunction<String, RootBeanDefinition, T> the function to invoke to resolve resolver)Resolve an inner bean definition and invoke the specified |
| private Object | Returns: the resolved inner bean instancethe name of the argument that the inner bean is defined for argName, String the name of the inner bean innerBeanName, RootBeanDefinition the merged bean definition for the inner bean mbd)Resolve an inner bean definition. |
| private Object | resolveManagedArray(Object argName, List<?> ml, Class<?> elementType)
For each element in the managed array, resolve reference if necessary. |
| private List | resolveManagedList(Object argName, List<?> ml)
For each element in the managed list, resolve reference if necessary. |
| private Map | resolveManagedMap(Object argName, Map<?, ?> mm)
For each element in the managed map, resolve reference if necessary. |
| private Set | resolveManagedSet(Object argName, Set<?> ms)
For each element in the managed set, resolve reference if necessary. |
| private Object | resolveReference(Object argName, RuntimeBeanReference ref)
Resolve a reference to another bean in the factory. |
| protected Class | Returns: the resolved target type (ornull if none specified)the TypedStringValue to resolve value)Resolve the target type in the given TypedStringValue. |
| public Object | Returns: the resolved objectthe name of the argument that the value is defined for argName, Object the value object to resolve value)Given a PropertyValue, return a value, resolving any references to other beans in the factory if necessary. |
| beanDefinition | back to summary |
|---|---|
| private final BeanDefinition beanDefinition | |
| beanFactory | back to summary |
|---|---|
| private final AbstractAutowireCapableBeanFactory beanFactory | |
| beanName | back to summary |
|---|---|
| private final String beanName | |
| typeConverter | back to summary |
|---|---|
| private final TypeConverter typeConverter | |
| BeanDefinitionValueResolver | back to summary |
|---|---|
| public BeanDefinitionValueResolver(AbstractAutowireCapableBeanFactory beanFactory, String beanName, BeanDefinition beanDefinition, TypeConverter typeConverter) Create a BeanDefinitionValueResolver for the given BeanFactory and BeanDefinition,
using the given
| |
| BeanDefinitionValueResolver | back to summary |
|---|---|
| public BeanDefinitionValueResolver(AbstractAutowireCapableBeanFactory beanFactory, String beanName, BeanDefinition beanDefinition) Create a BeanDefinitionValueResolver for the given BeanFactory and BeanDefinition
using a default
| |
| adaptInnerBeanName | back to summary |
|---|---|
| private String adaptInnerBeanName(String innerBeanName) Checks the given bean name whether it is unique. If not already unique, a counter is added, increasing the counter until the name is unique. | |
| doEvaluate | back to summary |
|---|---|
| private Object doEvaluate(String value) Evaluate the given String value as an expression, if necessary. | |
| evaluate | back to summary |
|---|---|
| protected Object evaluate(TypedStringValue value) Evaluate the given value as an expression, if necessary.
| |
| evaluate | back to summary |
|---|---|
| protected Object evaluate(Object value) Evaluate the given value as an expression, if necessary. | |
| resolveInnerBean | back to summary |
|---|---|
| public <T> T resolveInnerBean(String innerBeanName, BeanDefinition innerBd, BiFunction<String, RootBeanDefinition, T> resolver) Resolve an inner bean definition and invoke the specified
| |
| resolveInnerBeanValue | back to summary |
|---|---|
| private Object resolveInnerBeanValue(Object argName, String innerBeanName, RootBeanDefinition mbd) Resolve an inner bean definition.
| |
| resolveManagedArray | back to summary |
|---|---|
| private Object resolveManagedArray(Object argName, List<?> ml, Class<?> elementType) For each element in the managed array, resolve reference if necessary. | |
| resolveManagedList | back to summary |
|---|---|
| private List For each element in the managed list, resolve reference if necessary. | |
| resolveManagedMap | back to summary |
|---|---|
| private Map For each element in the managed map, resolve reference if necessary. | |
| resolveManagedSet | back to summary |
|---|---|
| private Set For each element in the managed set, resolve reference if necessary. | |
| resolveReference | back to summary |
|---|---|
| private Object resolveReference(Object argName, RuntimeBeanReference ref) Resolve a reference to another bean in the factory.
| |
| resolveTargetType | back to summary |
|---|---|
| protected Class Resolve the target type in the given TypedStringValue.
| |
| resolveValueIfNecessary | back to summary |
|---|---|
| public Object resolveValueIfNecessary(Object argName, Object value) Given a PropertyValue, return a value, resolving any references to other beans in the factory if necessary. The value could be: null, in which case it's left alone.
| |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public String |
| argName | back to summary |
|---|---|
| private final Object argName | |
| key | back to summary |
|---|---|
| private final Object key | |
| KeyedArgName | back to summary |
|---|---|
| public KeyedArgName(Object argName, Object key) | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Doc from java. Returns a string representation of the object. | |