@Override protected Class<?> getRepositoryBaseClass(RepositoryMetadata metadata) { if (isQueryDslExecutor(metadata.getRepositoryInterface())) { return QueryDslJpaRepository.class; } else { return JpaSupportRepository.class; } }
@Override protected Class<?> getRepositoryBaseClass(final RepositoryMetadata metadata) { if (isQueryDslExecutor(metadata.getRepositoryInterface())) { return QueryDslJpaRepository.class; } else { return GenericRepositoryImpl.class; } }
@Override @SuppressWarnings({ "unchecked", "rawtypes" }) protected <T, ID extends Serializable> SimpleJpaRepository<?, ?> getTargetRepository( final RepositoryMetadata metadata, final EntityManager entityManager) { Class<?> repositoryInterface = metadata.getRepositoryInterface(); JpaEntityInformation<?, Serializable> entityInformation = getEntityInformation(metadata.getDomainType()); if (isQueryDslExecutor(repositoryInterface)) { return new QueryDslJpaRepository(entityInformation, entityManager); } else { return new GenericRepositoryImpl(entityInformation, entityManager, namedQueryUtil); // custom } }