Answer Posted / shoban
Ioc is the core container for complete spring framework.
Ioc is designed to just perform "dependency injection".
Spring core module comes with basic spring container whose
name will be "BeanFactory"
Ioc can be designed based on Servicelocator designpattern.
Spring basically supports 2 kinds of injection
1.setter injection
2.constructor injection.
Based on the injection you choose and write proper java code
in bean class.
Dependency injection uses the hollywood principal "Don't
call me i will call u".
The steps to use Spring IOC are:
1. Write Java Bean classes, with getter and setter methods
for each property to be configured by Spring.
2. Create an XML file that describes the Java Beans to be
configured.
3. Use an XMLBeanFactory to create configured beans. There
are other ways to read bean descriptions, but using an
XmlBeanFactory is more common.
| Is This Answer Correct ? | 17 Yes | 4 No |
Post New Answer View All Answers
What is java collection? : java collections
What are the types of java collections? : java collections
What are the types of interface used in the java collections? : java collections
What are the types of the main implementing classes in the map interfaces? : java collections
What is the difference between comparable and comparator in java.util pkg?
who will give req's to u?. how they send req's to u? . what design documents contains?. when bugs raised on other developer code how to report to them?.(throgh mail or ........). how to retrive 100 recods from dao layer to presentation layer.using which collection?. what is sequence diagram.?.
What are maps interfaces in the java collections? : java collections
What are the classes in the java collection framework? : java collections
What is an algorithm in java collection framework? : java collections
What is the enumerator of the java collection framework? : java collections
Which java collection class can be used to maintain the entries in the order in which they were last accessed?
What is the Spring2.5 MVC Navigation flow?
can u draw class/object diagram for ATM
What are the queues in the java collection framework? : java collections
What is iterator in the java collections framework? : java collections