org.springframework.beans.factory.config
Interface ConfigurableListableBeanFactory

All Superinterfaces:
AutowireCapableBeanFactory, BeanFactory, ConfigurableBeanFactory, HierarchicalBeanFactory, ListableBeanFactory
All Known Implementing Classes:
DefaultListableBeanFactory

public interface ConfigurableListableBeanFactory
extends ListableBeanFactory, ConfigurableBeanFactory, AutowireCapableBeanFactory

SPI interface to be implemented by most if not all listable bean factories. In addition to ConfigurableBeanFactory, provides a way to pre-instantiate singletons.

Allows for framework-internal plug'n'play, e.g. in AbstractApplicationContext.

Since:
03.11.2003
Author:
Juergen Hoeller
See Also:
AbstractApplicationContext.getBeanFactory()

Field Summary
 
Fields inherited from interface org.springframework.beans.factory.config.AutowireCapableBeanFactory
AUTOWIRE_AUTODETECT, AUTOWIRE_BY_NAME, AUTOWIRE_BY_TYPE, AUTOWIRE_CONSTRUCTOR
 
Method Summary
 void preInstantiateSingletons()
          Ensure that all non-lazy-init singletons are instantiated, also considering FactoryBeans.
 
Methods inherited from interface org.springframework.beans.factory.ListableBeanFactory
containsBeanDefinition, getBeanDefinitionCount, getBeanDefinitionNames, getBeanDefinitionNames, getBeansOfType
 
Methods inherited from interface org.springframework.beans.factory.BeanFactory
containsBean, getAliases, getBean, getBean, isSingleton
 
Methods inherited from interface org.springframework.beans.factory.config.ConfigurableBeanFactory
addBeanPostProcessor, destroySingletons, getBeanDefinition, ignoreDependencyType, registerAlias, registerCustomEditor, registerSingleton, setParentBeanFactory
 
Methods inherited from interface org.springframework.beans.factory.HierarchicalBeanFactory
getParentBeanFactory
 
Methods inherited from interface org.springframework.beans.factory.config.AutowireCapableBeanFactory
applyBeanPostProcessorsAfterInitialization, applyBeanPostProcessorsBeforeInitialization, autowire, autowireBeanProperties
 

Method Detail

preInstantiateSingletons

public void preInstantiateSingletons()
                              throws BeansException
Ensure that all non-lazy-init singletons are instantiated, also considering FactoryBeans. Typically invoked at the end of factory setup, if desired.

As this is a startup method, it should destroy already created singletons if it fails, to avoid dangling resources. In other words, after invocation of that method, either all or no singletons at all should be instantiated.

Throws:
BeansException - if one of the singleton beans could not be created


Copyright (C) 2003-2004 The Spring Framework Project.