Spring BeanFactory Container:-
A BeanFactory is like a factory class that contains a collection of beans. The
BeanFactory holds Bean Definitions of multiple beans within itself and then
instantiates the bean whenever asked for by clients.
BeanFactory is able to create associations between collaborating objects
as they are instantiated. This removes the burden of configuration from bean
itself and the beans client.
BeanFactory also takes part in the life cycle of a bean, making calls to custom initialization and destruction methods.
This is the simplest container providing basic support for DI and
defined by the org.springframework.beans.factory.BeanFactory interface.
The BeanFactory and related interfaces, such as BeanFactoryAware,
InitializingBean, DisposableBean, are still present in Spring for the
purposes of backward compatibility with the large number of third-party
frameworks that integrate with Spring.
There are a number of implementations of the BeanFactory interface that come
supplied straight out-of-the-box with Spring. The most commonly used BeanFactory
implementation is the XmlBeanFactory class. This container reads the
configuration metadata from an XML file and uses it to create a fully configured
system or application.