Search Interview Questions | More than 3000 questions in repository. There are more than 900 unanswered questions. Click here and help us by providing the answer. Have a video suggestion. Click Correct / Improve and please let us know. |
|
| |||||||||||
Spring - Interview Questions and Answers for 'Spring annotation' - 3 question(s) found - Order By Newest | |||||||||||
| |||||||||||
Ans. @Autowired and @Inject are similar in terms of functionality they achieve. @Inject is part of a new Java technology called CDI that defines a standard for dependency injection whereas @Autowired is a Spring specific annotation for dependency injection. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  spring   web frameworks   dependency injection   autowired   inject   spring annotations   ioc | |||||||||||
Related Questions | |||||||||||
Explain Flow of Spring MVC ? | |||||||||||
What are the benefits of using Spring Framework ? | |||||||||||
What is MVC ? | |||||||||||
How spring boot works ? | |||||||||||
What is the difference between Singleton and Prototype Bean scope in Spring ? | |||||||||||
How can we manage Error Messages in the web application ? | |||||||||||
Difference between Java beans and Spring Beans ? | |||||||||||
What bean scopes does Spring support? Explain them. | |||||||||||
What are some differences between Spring caching and Hibernate caching? | |||||||||||
Can we have two beans with same class with different bean id in spring ? | |||||||||||
| |||||||||||
Ans. There are 2 ways to specify dependencies in Spring, one by the way of specifying beans in config files and other is by specifying annotations like @Bean, @Component , @Service etc to let spring know of the dependencies. | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  spring bean annotation  spring annotations | |||||||||||
Related Questions | |||||||||||
What is the difference betweeen @Inject and @Autowired ? | |||||||||||
How did you use Spring in your project ? Which Spring annotations have you used in your project ? | |||||||||||
| |||||||||||
Ans. @RequestMappping | |||||||||||
Help us improve. Please let us know the company, where you were asked this question : | |||||||||||
Like Discuss Correct / Improve  spring  spring annotations Asked in 1 Companies | |||||||||||
Related Questions | |||||||||||
What is the difference betweeen @Inject and @Autowired ? | |||||||||||
What is the use of @Bean annotation in Spring ? | |||||||||||
| |||||||||||