DATAJPA-1233 - Polishing.

Cleaned up JavaDoc.
Removed superfluous modifiers and initialisation code.
This commit is contained in:
Jens Schauder
2017-12-05 17:31:35 +01:00
committed by Oliver Gierke
parent d016d2e06a
commit 61bf237065
2 changed files with 7 additions and 7 deletions

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2008-2017 the original author or authors.
* Copyright 2008-2018 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -87,7 +87,8 @@ final class NamedQuery extends AbstractJpaQuery {
/**
* Returns whether the named query with the given name exists.
*
* @param em
* @param em must not be {@literal null}.
* @param queryName must not be {@literal null}.
* @return
*/
private static boolean hasNamedQuery(EntityManager em, String queryName) {
@@ -112,7 +113,8 @@ final class NamedQuery extends AbstractJpaQuery {
/**
* Looks up a named query for the given {@link org.springframework.data.repository.query.QueryMethod}.
*
* @param method
* @param method must not be {@literal null}.
* @param em must not be {@literal null}.
* @return
*/
@Nullable
@@ -154,7 +156,7 @@ final class NamedQuery extends AbstractJpaQuery {
protected TypedQuery<Long> doCreateCountQuery(Object[] values) {
EntityManager em = getEntityManager();
TypedQuery<Long> countQuery = null;
TypedQuery<Long> countQuery;
if (namedCountQueryIsPresent) {
countQuery = em.createNamedQuery(countQueryName, Long.class);

View File

@@ -72,12 +72,10 @@ public class ParameterBinderUnitTests {
}
static interface SampleRepository {
interface SampleRepository {
User useIndexedParameters(String lastname);
User indexedParameterWithSort(String lastname, Sort sort);
User valid(@Param("username") String username);
User validWithPageable(@Param("username") String username, Pageable pageable);