public class GenericScope extends Object implements org.springframework.beans.factory.config.Scope, org.springframework.beans.factory.config.BeanFactoryPostProcessor, org.springframework.beans.factory.support.BeanDefinitionRegistryPostProcessor, org.springframework.beans.factory.DisposableBean
A generic Scope implementation.
| Modifier and Type | Class and Description |
|---|---|
static class |
GenericScope.LockedScopedProxyFactoryBean<S extends GenericScope>
A factory bean with a locked scope.
|
| Modifier and Type | Field and Description |
|---|---|
static String |
SCOPED_TARGET_PREFIX
Prefix for the scoped target.
|
| Constructor and Description |
|---|
GenericScope() |
| Modifier and Type | Method and Description |
|---|---|
void |
destroy() |
protected boolean |
destroy(String name)
Destroys the named bean (i.e.
|
Object |
get(String name,
org.springframework.beans.factory.ObjectFactory<?> objectFactory) |
String |
getConversationId() |
Map<String,Exception> |
getErrors()
A map of bean name to errors when instantiating the bean.
|
protected ReadWriteLock |
getLock(String beanName) |
protected String |
getName() |
void |
postProcessBeanDefinitionRegistry(org.springframework.beans.factory.support.BeanDefinitionRegistry registry) |
void |
postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory) |
void |
registerDestructionCallback(String name,
Runnable callback) |
Object |
remove(String name) |
Object |
resolveContextualObject(String key) |
void |
setId(String id)
Manual override for the serialization ID that will be used to identify the bean
factory.
|
void |
setName(String name)
The name of this scope.
|
void |
setScopeCache(ScopeCache cache)
The cache implementation to use for bean instances in this scope.
|
public static final String SCOPED_TARGET_PREFIX
public void setId(String id)
id - The ID to set.public void setScopeCache(ScopeCache cache)
cache - The cache to use.public Map<String,Exception> getErrors()
public void destroy()
destroy in interface org.springframework.beans.factory.DisposableBeanprotected boolean destroy(String name)
name - The bean name to flush.public Object get(String name, org.springframework.beans.factory.ObjectFactory<?> objectFactory)
get in interface org.springframework.beans.factory.config.Scopepublic String getConversationId()
getConversationId in interface org.springframework.beans.factory.config.Scopepublic void registerDestructionCallback(String name, Runnable callback)
registerDestructionCallback in interface org.springframework.beans.factory.config.Scopepublic Object remove(String name)
remove in interface org.springframework.beans.factory.config.Scopepublic Object resolveContextualObject(String key)
resolveContextualObject in interface org.springframework.beans.factory.config.Scopepublic void postProcessBeanFactory(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactory)
throws org.springframework.beans.BeansException
postProcessBeanFactory in interface org.springframework.beans.factory.config.BeanFactoryPostProcessororg.springframework.beans.BeansExceptionpublic void postProcessBeanDefinitionRegistry(org.springframework.beans.factory.support.BeanDefinitionRegistry registry)
throws org.springframework.beans.BeansException
postProcessBeanDefinitionRegistry in interface org.springframework.beans.factory.support.BeanDefinitionRegistryPostProcessororg.springframework.beans.BeansExceptionprotected String getName()
public void setName(String name)
name - The name value to set.protected ReadWriteLock getLock(String beanName)
Copyright © 2020 Pivotal Software, Inc.. All rights reserved.