How to create your first project in spring using eclipse

152 views 30 slides Nov 22, 2016
Slide 1
Slide 1 of 30
Slide 1
1
Slide 2
2
Slide 3
3
Slide 4
4
Slide 5
5
Slide 6
6
Slide 7
7
Slide 8
8
Slide 9
9
Slide 10
10
Slide 11
11
Slide 12
12
Slide 13
13
Slide 14
14
Slide 15
15
Slide 16
16
Slide 17
17
Slide 18
18
Slide 19
19
Slide 20
20
Slide 21
21
Slide 22
22
Slide 23
23
Slide 24
24
Slide 25
25
Slide 26
26
Slide 27
27
Slide 28
28
Slide 29
29
Slide 30
30

About This Presentation

This presentation has been created for eclipse users who are stuck at being unable to grasp how to start with spring.
This guide is meant only as a reference and is a walk-through.
No explanations have been provided.


Slide Content

How to create your first project in Spring using eclipse Author : Rajorshi Mukherjee Abstract: This is just a brief walkthrough. NO explanations have been provided.

First Steps First download eclipse. (I used Mars as that is the latest version) (http://www.eclipse.org/downloads/packages/eclipse-ide-java-ee-developers/mars2) I recommend downloading JEE version as it can also be used for web app development. JDK 8+ is required to work with this. (http://www.oracle.com/technetwork/java/javase/downloads/jdk8-downloads-2133151.html) Download apache commons logging (using v 1.2) (https://commons.apache.org/proper/commons-logging/download_logging.cgi) Download Spring Framework Release (using 4.3.1) (https://repo.spring.io/release/org/springframework/spring/)

Change perspective to java and Create a new Java Project

Assign Name to project and click finish

Right click and goto build path->configure build path

Libraries-> Add External Jars

Add All Spring Files

Add Apache Commons Logging

All added jars will be shown

Added Jars can be found in Referenced Libraries

Create a new package in src folder

Give a name and click finish

Create a new inteface

Give a name and hit finish

Add 2 public methods to the interface

Create a new class inside the package

Give a name and hit finish

Add implements interface

Mouse hover at red warning and add unimplemented methods

Create default constructor and assign value to private String message and define the other two functions

Again create a new class

Give a name and hit finish

This class will contain main method and relevant business logic

Rt-Click src folder and goto new -> other

Search xml and select xml file -> hit next

Give a name to the file and hit finish

Add the mandatory beans header and create two beans inside it referencing two separate functions in the same implementation class

Finally Rt-Click Project and goto Run as Java App

You should see desired output in the bottom console

Thanks for your time Regards, Rajorshi Mukherjee