Springcore Part1
Springcore Part1
• 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.
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