- Spring - Home
- Spring - Overview
- Spring - Architecture
- Spring - Environment Setup
- Spring - Hello World Example
- Spring - IoC Containers
- Spring - Bean Definition
- Spring - Bean Scopes
- Spring - Bean Life Cycle
- Spring - Bean Post Processors
- Spring - Bean Definition Inheritance
- Spring - Dependency Injection
- Spring - Injecting Inner Beans
- Spring - Injecting Collection
- Spring - Beans Auto-Wiring
- Annotation Based Configuration
- Spring - Java Based Configuration
- Spring - Event Handling in Spring
- Spring - Custom Events in Spring
- Spring - AOP with Spring Framework
- Spring - JDBC Framework
- Spring - Transaction Management
- Spring - Web MVC Framework
- Spring - Logging with Log4J
Spring Useful Resources
Spring Online Quiz
Following quiz provides Multiple Choice Questions (MCQs) related to Spring Framework. You will have to read all the given answers and click over the correct answer. If you are not sure about the answer then you can check the answer using Show Answer button. You can use Next Quiz button to check new set of questions in the quiz.
Answer : A
Explanation
AOP stands for Aspect Oriented Programming.
Q 2 - Which of the following stands true for spring beans?
A - Spring beans are managed by the Spring IoC container.
B - Spring beans are instantiated, assembled, and otherwise managed by a Spring IoC container.
Answer : D
Explanation
All of the above statements are correct.
Q 3 - What is true about <map> collection configuration elements?
A - This helps in wiring a list of values, allowing duplicates.
B - This helps in wiring a list of values but without any duplicates.
Answer : C
Explanation
<map> tag is used to inject a collection of name-value pairs where name and value can be of any type.
Q 4 - What does @Required annotation mean?
A - This annotation indicates that bean property must be populated by the user.
B - This annotation indicates that bean property is required while saving the bean data to database.
D - This annotation indicates that bean property is required while serializing the bean.
Answer : C
Explanation
@Required annotation simply indicates that the affected bean property must be populated at configuration time, through an explicit property value in a bean definition or through autowiring.
Q 5 - What is Pointcut?
A - This represents a point in your application where you can plug-in AOP aspect.
B - This is a set of one or more joinpoints where an advice should be executed.
C - This is used to inject values in objects.
D - This is invoked during program execution by Spring AOP framework.
Answer : B
Explanation
Pointcut is a set of one or more joinpoints where an advice should be executed.
Q 6 - What are the different points where weaving can be applied?
Answer : D
Explanation
Weaving can be applied at Compile time, load Time and Run time.
Answer : B
Explanation
AOP is not the part of spring core container.
Answer : A
Explanation
Struts can be integrated with spring.
Q 9 - How to handle shut down of IoC container?
Answer : D
Explanation
Using registerShutdownHook() method, shut down of IoC container can be handled. Other methods do not exists.
Q 10 - What is true about BeanPostProcessor?
Answer : B
Explanation
BeanPostProcessor is an interface.