Wednesday, June 26, 2013

Hello World Example With Spring Framework


- Create a Java Project in My Eclipse, Add 'Spring3.1' Capabilities, By right clicking on Project->MyEclipse->Project Facets(Capabilities)->Spriing Facet
This will load required libraries in the class path.

- Create a Customer POJO as shown below, with  one parameterized constructor and to data members


- Update applicationContext.xml as shown below by configuring the bean details.

- Write a simple Test class as shown below, Right click on this class and run as java application

- You should see below output by running above class

1 comment: