0% found this document useful (0 votes)
2 views8 pages

Springcore Part1

The Spring Framework is a lightweight, open-source Java framework designed for fast and easy enterprise application development, created by Rod Johnson in 2003. It supports various other frameworks and includes modules like IOC, AOP, and WEB MVC, while providing advantages such as dependency injection for loose coupling and easier testing. The core of Spring is its IOC container, which manages object creation and dependencies, and can be configured using XML or annotations.

Uploaded by

bandarikavya568
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views8 pages

Springcore Part1

The Spring Framework is a lightweight, open-source Java framework designed for fast and easy enterprise application development, created by Rod Johnson in 2003. It supports various other frameworks and includes modules like IOC, AOP, and WEB MVC, while providing advantages such as dependency injection for loose coupling and easier testing. The core of Spring is its IOC container, which manages object creation and dependencies, and can be configured using XML or annotations.

Uploaded by

bandarikavya568
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 8

SPRING FRAMEWORK

• Spring is a lightweight , open source , java based framework which


makes application development easy and fast.

• It is developed by Rod Johnson in 2003.

• It is used to develop enterprise level applications.

• It is known as a framework of frameworks because it provides


support to various other frameworks such as Hibernate, JPA etc.

• The spring framework, in other words can be defined as a structure


where we find solution of the various technical problems.

• The Spring framework comprises several modules such as IOC, AOP,


DAO, Context, ORM, WEB MVC etc.
Advantages of Spring Framework

• Spring framework provides predefined templates for JDBC, Hibernate, JPA


etc. technologies. So there is no need to write too much code. It hides the
basic steps of these technologies.

• The Spring applications are loosely coupled because of dependency


injection.

• The Dependency Injection in spring framework makes it easier to test the


applications.

• Spring framework is lightweight because of its POJO implementation. The


Spring Framework doesn't force the programmer to inherit any class or
implement any interface.

• The Dependency Injection feature of Spring Framework and it support to


various frameworks makes the easy development of JavaEE application.
Inversion Of Control (IOC) and Dependency Injection

• These are the design patterns that are used to remove dependency from the
programming code. They make the code easier to test and maintain.
• Spring IOC container is the core of spring framework. It is made up of core
container and J2EE container.
• The IOC container uses Dependency Injection(DI) to manage the components.
• It creates the objects , configures, assembles their dependencies and
manages their entire life cycle.
• The objects created and managed by IOC container are known as spring
beans.
• Since the controlling of objects is not by programmer , instead done by
spring container , it is called as inversion of control.
• The main features of spring IOC container are :
1. Creating object .
2. managing the object dependencies
3. Helps the application to be configurable.

• IOC containers are of two types :


1. BeanFactory (Core container)
2. ApplicationContext (J2EE container).

• BeanFactory and ApplicationContext are both interfaces


which acts as IOC containers.
BeanFactory interface :
It is the most basic version of IOC container providing a configuration
mechanism to instantiate , configure and manage the life cycle of objects.
The BeanFactory loads the bean definitions and their dependencies
based on xml file only. It doesn’t support annotations based
configuration.

AnnotationContext interface :
It is the sub interface of BeanFactory interface. Hence , it supports all the
features of BeanFactory interface.
It is the advanced version of IOC container providing a easy
configuration mechanism to instantiate , configure and manage the life
cycle of objects.
It supports xml based configurations as well as supports annotation
based configuration.
Information about object creation can be provided to IOC
container in two ways :
1. Using XML file
2. Using annotations

You might also like