In this example you will know about spring bean life cycle and how a bean is initialized in the program. The bean factory container search for bean definition and also instantiates the bean.
BeanMain.java
package net.roseindia;
|
BeanFirst.java
package net.roseindia;
|
BeanSecond.java
package net.roseindia;
|
BeanThird.java
package net.roseindia;
|
context.xml
<?xml version="1.0" encoding="UTF-8"?>
|
| BeanSecond constructior is called Init of BeanSecond method called BeanFirst constructor is called Construictor Called for BeanThird Setter method for BeanFirst called in BeanThird Init Called for BeanThird Setter method called for the BeanThird Init of BeanFirst method called |