Class DefaultRepositoryInvokerFactory
java.lang.Object
org.springframework.data.repository.support.DefaultRepositoryInvokerFactory
- All Implemented Interfaces:
RepositoryInvokerFactory
Default implementation of
RepositoryInvokerFactory
to inspect the requested repository type and create a
matching RepositoryInvoker
that suits the repository best. That means, the more concrete the base interface
of the repository is, the more concrete will the actual invoker become - which means it will favor concrete method
invocations over reflection ones.- Since:
- 1.10
- Author:
- Oliver Gierke, Christoph Strobl
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultRepositoryInvokerFactory
(Repositories repositories) Creates a newDefaultRepositoryInvokerFactory
for the givenRepositories
.DefaultRepositoryInvokerFactory
(Repositories repositories, ConversionService conversionService) -
Method Summary
Modifier and TypeMethodDescriptionprotected RepositoryInvoker
createInvoker
(RepositoryInformation information, Object repository) getInvokerFor
(Class<?> domainType) Returns theRepositoryInvoker
for a repository managing the given domain type.
-
Constructor Details
-
DefaultRepositoryInvokerFactory
Creates a newDefaultRepositoryInvokerFactory
for the givenRepositories
.- Parameters:
repositories
- must not be null.
-
DefaultRepositoryInvokerFactory
public DefaultRepositoryInvokerFactory(Repositories repositories, ConversionService conversionService) - Parameters:
repositories
- must not be null.conversionService
- must not be null.
-
-
Method Details
-
getInvokerFor
Description copied from interface:RepositoryInvokerFactory
Returns theRepositoryInvoker
for a repository managing the given domain type.- Specified by:
getInvokerFor
in interfaceRepositoryInvokerFactory
- Parameters:
domainType
- must not be null.- Returns:
-
createInvoker
-