@Repository: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
|||
(9 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
=External= | |||
* https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/stereotype/Repository.html | |||
=Internal= | =Internal= | ||
* [[Spring_Dependency_Injection_and_Inversion_of_Control_Container_Concepts# | * [[Spring_Dependency_Injection_and_Inversion_of_Control_Container_Concepts#Stereotypes|Spring Dependency Injection and Inversion of Control Container Concepts]] | ||
* [[ | * [[Spring_Persistence_Concepts#Repository|Spring Persistence Concepts]] | ||
=Overview= | |||
@Repository is a [[Spring_Dependency_Injection_and_Inversion_of_Control_Container_Concepts#Stereotype|stereotype annotation]] for the persistence layer that lets [[Spring_Dependency_Injection_and_Inversion_of_Control_Container_Concepts#Component_Scanning|component scanning]] find and configure the [[Spring_Persistence_Concepts#DAO|DAOs]] and [[Spring_Persistence_Concepts#Repository|repositories]] without having to provide XML configuration entries for them. The annotation indicates that the class should be automatically discovered by component scanning and instantiated as a bean in the Spring application context. |
Latest revision as of 01:51, 4 November 2018
External
Internal
Overview
@Repository is a stereotype annotation for the persistence layer that lets component scanning find and configure the DAOs and repositories without having to provide XML configuration entries for them. The annotation indicates that the class should be automatically discovered by component scanning and instantiated as a bean in the Spring application context.