Skip to content

Commit 4864ee3

Browse files
committed
Polish
- Polish javadoc - Make ReindexerQueryExecutionConverters package private - Add since tag
1 parent 74c321e commit 4864ee3

File tree

4 files changed

+7
-21
lines changed

4 files changed

+7
-21
lines changed

src/main/java/org/springframework/data/reindexer/repository/support/ReindexerAnnotationRepositoryMetadata.java

-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
import java.lang.reflect.Method;
1919

20-
import org.springframework.data.reindexer.repository.util.ReindexerQueryExecutionConverters;
2120
import org.springframework.data.repository.core.support.AnnotationRepositoryMetadata;
2221
import org.springframework.data.repository.util.ReactiveWrapperConverters;
2322
import org.springframework.data.util.TypeInformation;

src/main/java/org/springframework/data/reindexer/repository/support/ReindexerDefaultRepositoryMetadata.java

-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
import java.lang.reflect.Method;
1919

20-
import org.springframework.data.reindexer.repository.util.ReindexerQueryExecutionConverters;
2120
import org.springframework.data.repository.core.support.DefaultRepositoryMetadata;
2221
import org.springframework.data.repository.util.ReactiveWrapperConverters;
2322
import org.springframework.data.util.TypeInformation;
+4-17
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16-
package org.springframework.data.reindexer.repository.util;
16+
package org.springframework.data.reindexer.repository.support;
1717

1818
import java.util.stream.Stream;
1919

@@ -26,28 +26,16 @@
2626
import org.springframework.util.Assert;
2727

2828
/**
29-
* Converters to potentially wrap the execution of a repository method into a variety of wrapper types
30-
* potentially being available on the classpath.
31-
* @see QueryExecutionConverters
29+
* For internal use only, as this contract is likely to change.
3230
*
3331
* @author Evgeniy Cheban
3432
*/
35-
public final class ReindexerQueryExecutionConverters {
33+
final class ReindexerQueryExecutionConverters {
3634

3735
private ReindexerQueryExecutionConverters() {
3836
}
3937

40-
/**
41-
* Recursively unwraps well known wrapper types from the given {@link TypeInformation} but aborts at the given
42-
* reference type.
43-
* This method is a copy of {@link QueryExecutionConverters#unwrapWrapperTypes(TypeInformation, TypeInformation)}
44-
* with extension of adding {@link ResultIterator} type check.
45-
*
46-
* @param type must not be {@literal null}.
47-
* @param reference must not be {@literal null}.
48-
* @return will never be {@literal null}.
49-
*/
50-
public static TypeInformation<?> unwrapWrapperTypes(TypeInformation<?> type, TypeInformation<?> reference) {
38+
static TypeInformation<?> unwrapWrapperTypes(TypeInformation<?> type, TypeInformation<?> reference) {
5139
Assert.notNull(type, "type must not be null");
5240
if (reference.isAssignableFrom(type)) {
5341
return type;
@@ -62,5 +50,4 @@ public static TypeInformation<?> unwrapWrapperTypes(TypeInformation<?> type, Typ
6250
|| ResultIterator.class.isAssignableFrom(rawType);
6351
return needToUnwrap ? unwrapWrapperTypes(type.getRequiredComponentType(), reference) : type;
6452
}
65-
6653
}

src/main/java/org/springframework/data/reindexer/repository/util/PageableUtils.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,11 @@
1919
import org.springframework.data.domain.Pageable;
2020

2121
/**
22-
* Provide a set of utility methods to support {@link Pageable}s.
22+
* Provides a set of utility methods to support {@link Pageable}s.
2323
*
2424
* @author Greg Turnquist
2525
* @author Evgeniy Cheban
26+
* @since 1.3
2627
*/
2728
public final class PageableUtils {
2829

@@ -31,7 +32,7 @@ private PageableUtils() {
3132
}
3233

3334
/**
34-
* Convert a {@link Pageable}'s offset value from {@link Long} to {@link Integer} to support JPA spec methods.
35+
* Converts a {@link Pageable}'s offset value from {@link Long} to {@link Integer}.
3536
*
3637
* @param pageable the {@link Pageable} to use
3738
* @return integer

0 commit comments

Comments
 (0)