Skip to content

Commit ab8e39e

Browse files
committed
Fix Javadoc.
Fix invalid links. Replace Javadoc links to JSR-305 with code annotations. Replace self-enclosing tags with simple ones. See #2423
1 parent 9478278 commit ab8e39e

File tree

53 files changed

+101
-114
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+101
-114
lines changed

Diff for: src/main/java/org/springframework/data/annotation/PersistenceConstructor.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
import java.lang.annotation.Target;
2222

2323
/**
24-
* @author Jon Brisbin <[email protected]>
24+
* @author Jon Brisbin
2525
*/
2626
@Retention(RetentionPolicy.RUNTIME)
2727
@Target(ElementType.CONSTRUCTOR)

Diff for: src/main/java/org/springframework/data/auditing/IsNewAwareAuditingHandler.java

+3-5
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,6 @@
1515
*/
1616
package org.springframework.data.auditing;
1717

18-
import java.util.Optional;
19-
2018
import org.springframework.data.mapping.PersistentEntity;
2119
import org.springframework.data.mapping.PersistentProperty;
2220
import org.springframework.data.mapping.context.MappingContext;
@@ -26,8 +24,8 @@
2624

2725
/**
2826
* {@link AuditingHandler} extension that uses {@link PersistentEntity#isNew(Object)} to expose a generic
29-
* {@link #markAudited(Optional)} method that will route calls to {@link #markCreated(Optional)} or
30-
* {@link #markModified(Optional)} based on the {@link IsNewStrategy} determined from the factory.
27+
* {@link #markAudited(Object)} method that will route calls to {@link #markCreated(Object)} or
28+
* {@link #markModified(Object)} based on the {@link IsNewStrategy} determined from the factory.
3129
*
3230
* @author Oliver Gierke
3331
* @author Christoph Strobl
@@ -65,7 +63,7 @@ public IsNewAwareAuditingHandler(PersistentEntities entities) {
6563

6664
/**
6765
* Marks the given object created or modified based on {@link PersistentEntity#isNew(Object)}. Will route the calls to
68-
* {@link #markCreated(Optional)} and {@link #markModified(Optional)} accordingly.
66+
* {@link #markCreated(Object)} and {@link #markModified(Object)} accordingly.
6967
*
7068
* @param object must not be {@literal null}.
7169
*/

Diff for: src/main/java/org/springframework/data/domain/Sort.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -402,7 +402,7 @@ public Order(@Nullable Direction direction, String property) {
402402
*
403403
* @param direction can be {@literal null}, will default to {@link Sort#DEFAULT_DIRECTION}
404404
* @param property must not be {@literal null} or empty.
405-
* @param nullHandling must not be {@literal null}.
405+
* @param nullHandlingHint must not be {@literal null}.
406406
*/
407407
public Order(@Nullable Direction direction, String property, NullHandling nullHandlingHint) {
408408
this(direction, property, DEFAULT_IGNORE_CASE, nullHandlingHint);

Diff for: src/main/java/org/springframework/data/domain/jaxb/SpringDataJaxb.java

-2
Original file line numberDiff line numberDiff line change
@@ -108,7 +108,6 @@ public static class PageDto extends RepresentationModel {
108108
* @param source
109109
* @param adapter must not be {@literal null}.
110110
* @return
111-
* @throws Exception
112111
*/
113112
public static <T, S> List<T> unmarshal(Collection<S> source, XmlAdapter<S, T> adapter) {
114113

@@ -136,7 +135,6 @@ public static <T, S> List<T> unmarshal(Collection<S> source, XmlAdapter<S, T> ad
136135
* @param source
137136
* @param adapter must not be {@literal null}.
138137
* @return
139-
* @throws Exception
140138
*/
141139
public static <T, S> List<S> marshal(@Nullable Iterable<T> source, XmlAdapter<S, T> adapter) {
142140

Diff for: src/main/java/org/springframework/data/geo/GeoPage.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public class GeoPage<T> extends PageImpl<GeoResult<T>> {
4141
/**
4242
* Creates a new {@link GeoPage} from the given {@link GeoResults}.
4343
*
44-
* @param content must not be {@literal null}.
44+
* @param results must not be {@literal null}.
4545
*/
4646
public GeoPage(GeoResults<T> results) {
4747

Diff for: src/main/java/org/springframework/data/geo/format/DistanceFormatter.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
/**
3434
* Converter to create {@link Distance} instances from {@link String} representations. The supported format is a decimal
3535
* followed by whitespace and a metric abbreviation. We currently support the following abbreviations:
36-
* {@value #SUPPORTED_METRICS}.
36+
* {@link #SUPPORTED_METRICS}.
3737
*
3838
* @author Oliver Gierke
3939
* @author Christoph Strobl

Diff for: src/main/java/org/springframework/data/history/AnnotationRevisionMetadata.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929

3030
/**
3131
* A {@link RevisionMetadata} implementation that inspects the given object for fields with the configured annotations
32-
* and returns the field's values on calls to {@link #getRevisionDate()}, {@link #getRevisionInstant()} and
32+
* and returns the field's values on calls to {@link #getRevisionInstant()}, {@link #getRevisionInstant()} and
3333
* {@link #getRevisionNumber()}.
3434
*
3535
* @author Oliver Gierke

Diff for: src/main/java/org/springframework/data/mapping/Alias.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,10 @@
2222
/**
2323
* A container object which may or may not contain a type alias value. If a value is present, {@code isPresent()} will
2424
* return {@code true} and {@link #getValue()} will return the value.
25-
* <p/>
25+
* <p>
2626
* Additional methods that depend on the presence or absence of a contained value are provided, such as
2727
* {@link #hasValue(Object)} or {@link #isPresent()}
28-
* <p/>
28+
* <p>
2929
* Aliases are immutable once created.
3030
*
3131
* @author Oliver Gierke

Diff for: src/main/java/org/springframework/data/mapping/Association.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
* Value object to capture {@link Association}s.
2222
*
2323
* @param <P> {@link PersistentProperty}s the association connects.
24-
* @author Jon Brisbin <[email protected]>
24+
* @author Jon Brisbin
2525
* @author Mark Paluch
2626
*/
2727
public class Association<P extends PersistentProperty<P>> {

Diff for: src/main/java/org/springframework/data/mapping/AssociationHandler.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
/**
1919
* Callback interface to implement functionality to be applied to a collection of {@link Association}s.
2020
*
21-
* @author Jon Brisbin <[email protected]>
21+
* @author Jon Brisbin
2222
* @author Oliver Gierke
2323
*/
2424
public interface AssociationHandler<P extends PersistentProperty<P>> {

Diff for: src/main/java/org/springframework/data/mapping/MappingException.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
import org.springframework.lang.Nullable;
1919

2020
/**
21-
* @author Jon Brisbin <[email protected]>
21+
* @author Jon Brisbin
2222
*/
2323
public class MappingException extends RuntimeException {
2424

Diff for: src/main/java/org/springframework/data/mapping/PersistentProperty.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ default Method getRequiredSetter() {
128128
/**
129129
* Returns the with {@link Method} to set a property value on a new object instance. Might return {@literal null} in
130130
* case there is no with available.
131-
* <p/>
131+
* <p>
132132
* With {@link Method methods} are property-bound instance {@link Method methods} that accept a single argument of the
133133
* property type creating a new object instance.
134134
*

Diff for: src/main/java/org/springframework/data/mapping/PersistentPropertyAccessor.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
* Domain service to allow accessing and setting {@link PersistentProperty}s of an entity. Usually obtained through
2424
* {@link PersistentEntity#getPropertyAccessor(Object)}. In case type conversion shall be applied on property access,
2525
* use a {@link ConvertingPropertyAccessor}.
26-
* <p />
26+
* <p>
2727
* This service supports mutation for immutable classes by creating new object instances. These are managed as state of
2828
* {@link PersistentPropertyAccessor} and must be obtained from {@link #getBean()} after processing all updates.
2929
*

Diff for: src/main/java/org/springframework/data/mapping/PersistentPropertyPathAccessor.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ default Object getProperty(PersistentPropertyPath<? extends PersistentProperty<?
6161
*
6262
* @param path must not be {@literal null} or empty.
6363
* @param value can be {@literal null}.
64-
* @see AccessOptions#DEFAULT
64+
* @see AccessOptions#defaultSetOptions()
6565
*/
6666
void setProperty(PersistentPropertyPath<? extends PersistentProperty<?>> path, @Nullable Object value);
6767

Diff for: src/main/java/org/springframework/data/mapping/PropertyHandler.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
* Callback interface to do something with all plain {@link PersistentProperty} instances <em>except</em> associations
2020
* and transient properties.
2121
*
22-
* @author Jon Brisbin <[email protected]>
22+
* @author Jon Brisbin
2323
*/
2424
public interface PropertyHandler<P extends PersistentProperty<P>> {
2525

Diff for: src/main/java/org/springframework/data/mapping/callback/EntityCallback.java

+5-6
Original file line numberDiff line numberDiff line change
@@ -19,29 +19,28 @@
1919
* Marker interface for entity callbacks to be implemented in specific callback subtypes. Intended for internal usage
2020
* within store specific implementations.
2121
* <h3>Ordering {@link EntityCallback}</h3>
22-
* <p/>
22+
* <p>
2323
* Multiple entity callbacks are invoked sequentially with the result of the previous callback. Callbacks are unordered
2424
* by default. It is possible to define the order in which listeners for a certain domain type are to be invoked. To do
2525
* so, add Spring's common {@link org.springframework.core.annotation.Order @Order} annotation or implement
2626
* {@link org.springframework.core.Ordered}.
2727
* <h3>Exception Handling</h3>
28-
* <p />
28+
* <p>
2929
* While it is possible for a {@link EntityCallback} to declare that it throws arbitrary exception types, any checked
3030
* exceptions thrown from a {@link EntityCallback} are wrapped in an
3131
* {@link java.lang.reflect.UndeclaredThrowableException UndeclaredThrowableException} since the callback mechanism can
3232
* only handle runtime exceptions. Entity callback processing is stopped on the {@link EntityCallback} that raised an
3333
* exception and the caused exception is propagated to the caller.
3434
* <h3>Domain Type Binding</h3>
35-
* <p />
35+
* <p>
3636
* An {@link EntityCallback} can generically declare the domain type that it is able to process by specifying the
3737
* generic type parameter {@code <T>}. When registered with a Spring
3838
* {@link org.springframework.context.ApplicationContext}, callbacks are filtered accordingly, with the callback getting
3939
* invoked for assignable domain objects only.
40-
* <p/>
40+
* <p>
4141
* Typically, entity callbacks are invoked after publishing {@link org.springframework.context.ApplicationEvent events}.
42-
* <p/>
4342
* <h3>Defining {@link EntityCallback} Interfaces</h3>
44-
* <p />
43+
* <p>
4544
* A {@link EntityCallback} interface needs to define a callback method accepting an object of the parameterized type as
4645
* its first argument followed by additional <i>optional</i> arguments.
4746
*

Diff for: src/main/java/org/springframework/data/mapping/callback/EntityCallbackDiscoverer.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ class EntityCallbackDiscoverer {
6464

6565
/**
6666
* Create a new {@link EntityCallback} instance.
67-
* <p />
67+
* <p>
6868
* Pre loads {@link EntityCallback} beans by scanning the {@link BeanFactory}.
6969
*/
7070
EntityCallbackDiscoverer(BeanFactory beanFactory) {

Diff for: src/main/java/org/springframework/data/mapping/callback/EntityCallbacks.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ static EntityCallbacks create() {
7272

7373
/**
7474
* Obtain a new {@link EntityCallbacks} instance.
75-
* <p />
75+
* <p>
7676
* {@link EntityCallback callbacks} are pre loaded from the given {@link BeanFactory}. <br />
7777
* Use {@link #addEntityCallback(EntityCallback)} to register additional callbacks manually.
7878
*

Diff for: src/main/java/org/springframework/data/mapping/callback/ReactiveEntityCallbacks.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ static ReactiveEntityCallbacks create() {
7575

7676
/**
7777
* Obtain a new {@link ReactiveEntityCallbacks} instance.
78-
* <p />
78+
* <p>
7979
* {@link EntityCallback callbacks} are pre loaded from the given {@link BeanFactory}. <br />
8080
* Use {@link #addEntityCallback(EntityCallback)} to register additional callbacks manually.
8181
*

Diff for: src/main/java/org/springframework/data/mapping/context/AbstractMappingContext.java

-1
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,6 @@ public void initialize() {
479479
* default this will reject all types considered simple and non-supported Kotlin classes, but it might be necessary to
480480
* tweak that in case you have registered custom converters for top level types (which renders them to be considered
481481
* simple) but still need meta-information about them.
482-
* <p/>
483482
*
484483
* @param type will never be {@literal null}.
485484
* @return

Diff for: src/main/java/org/springframework/data/mapping/context/InvalidPersistentPropertyPath.java

+1-2
Original file line numberDiff line numberDiff line change
@@ -49,8 +49,7 @@ public class InvalidPersistentPropertyPath extends MappingException {
4949
*
5050
* @param source must not be {@literal null}.
5151
* @param unresolvableSegment must not be {@literal null} or empty.
52-
* @param resolvedPath
53-
* @param message must not be {@literal null} or empty.
52+
* @param resolvedPath must not be {@literal null} or empty.
5453
*/
5554
public InvalidPersistentPropertyPath(String source, TypeInformation<?> type, String unresolvableSegment,
5655
PersistentPropertyPath<? extends PersistentProperty<?>> resolvedPath) {

Diff for: src/main/java/org/springframework/data/mapping/model/KotlinClassGeneratingEntityInstantiator.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,7 @@ private static boolean parametersMatch(java.lang.reflect.Parameter[] constructor
159159
* <li>{@code DefaultConstructorMarker} (usually null)</li>
160160
* </ul>
161161
* <strong>Defaulting bitmask</strong>
162-
* <p/>
162+
* <p>
163163
* The defaulting bitmask is a 32 bit integer representing which positional argument should be defaulted. Defaulted
164164
* arguments are passed as {@literal null} and require the appropriate positional bit set ( {@code 1 << 2} for the 2.
165165
* argument)). Since the bitmask represents only 32 bit states, it requires additional masks (slots) if more than 32

Diff for: src/main/java/org/springframework/data/querydsl/binding/QuerydslBindings.java

+1-3
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ public final void excluding(Path<?>... paths) {
136136
/**
137137
* Include properties for binding. Include the property considered a binding candidate.
138138
*
139-
* @param properties must not be {@literal null} or empty.
139+
* @param paths must not be {@literal null} or empty.
140140
*/
141141
public final void including(Path<?>... paths) {
142142

@@ -388,7 +388,6 @@ public class PathBinder<P extends Path<? extends T>, T> {
388388
* Defines the given {@link SingleValueBinding} to be used for the paths.
389389
*
390390
* @param binding must not be {@literal null}.
391-
* @return
392391
*/
393392
public void firstOptional(OptionalValueBinding<P, T> binding) {
394393

@@ -407,7 +406,6 @@ public void first(SingleValueBinding<P, T> binding) {
407406
* Defines the given {@link MultiValueBinding} to be used for the paths.
408407
*
409408
* @param binding must not be {@literal null}.
410-
* @return
411409
*/
412410
public void all(MultiValueBinding<P, T> binding) {
413411

Diff for: src/main/java/org/springframework/data/repository/NoRepositoryBean.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@
2424
/**
2525
* Annotation to exclude repository interfaces from being picked up and thus in consequence getting an instance being
2626
* created.
27-
* <p/>
27+
* <p>
2828
* This will typically be used when providing an extended base interface for all repositories in combination with a
2929
* custom repository base class to implement methods declared in that intermediate interface. In this case you typically
3030
* derive your concrete repository interfaces from the intermediate one but don't want to create a Spring bean for the

Diff for: src/main/java/org/springframework/data/repository/config/CustomRepositoryImplementationDetector.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,7 @@
3434
* configured with a {@link ImplementationDetectionConfiguration} at construction time, the necessary component scan is
3535
* executed on first access, cached and its result is the filtered on every further implementation lookup according to
3636
* the given {@link ImplementationDetectionConfiguration}. If none is given initially, every invocation to
37-
* {@link #detectCustomImplementation(String, String, ImplementationDetectionConfiguration)} will issue a new component
38-
* scan.
37+
* {@link #detectCustomImplementation(ImplementationLookupConfiguration)} will issue a new component scan.
3938
*
4039
* @author Oliver Gierke
4140
* @author Mark Paluch
@@ -57,7 +56,7 @@ public class CustomRepositoryImplementationDetector {
5756
* Creates a new {@link CustomRepositoryImplementationDetector} with the given {@link Environment},
5857
* {@link ResourceLoader} and {@link ImplementationDetectionConfiguration}. The latter will be registered for a
5958
* one-time component scan for implementation candidates that will the be used and filtered in all subsequent calls to
60-
* {@link #detectCustomImplementation(RepositoryConfiguration)}.
59+
* {@link #detectCustomImplementation(ImplementationLookupConfiguration)}.
6160
*
6261
* @param environment must not be {@literal null}.
6362
* @param resourceLoader must not be {@literal null}.

Diff for: src/main/java/org/springframework/data/repository/config/RepositoryBeanDefinitionParser.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,8 @@
3333

3434
/**
3535
* Base class to implement repository namespaces. These will typically consist of a main XML element potentially having
36-
* child elements. The parser will wrap the XML element into a {@link GlobalRepositoryConfigInformation} object and
37-
* allow either manual configuration or automatic detection of repository interfaces.
36+
* child elements. The parser will wrap the XML element into a {@link XmlRepositoryConfigurationSource} object and allow
37+
* either manual configuration or automatic detection of repository interfaces.
3838
*
3939
* @author Oliver Gierke
4040
*/

Diff for: src/main/java/org/springframework/data/repository/config/RepositoryConfigurationExtension.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ <T extends RepositoryConfigurationSource> Collection<RepositoryConfiguration<T>>
7171
* repositories bean definitions have been registered.
7272
*
7373
* @param registry
74-
* @param source
74+
* @param configurationSource
7575
*/
7676
void registerBeansForRoot(BeanDefinitionRegistry registry, RepositoryConfigurationSource configurationSource);
7777

Diff for: src/main/java/org/springframework/data/repository/core/support/MethodInvocationValidator.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
*
4242
* @author Mark Paluch
4343
* @since 2.0
44-
* @see javax.annotation.Nonnull
44+
* @see org.springframework.lang.NonNull
4545
* @see ReflectionUtils#isNullable(MethodParameter)
4646
* @see NullableUtils
4747
*/

Diff for: src/main/java/org/springframework/data/repository/core/support/MethodLookup.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@
2727
/**
2828
* Strategy interface providing {@link MethodPredicate predicates} to resolve a method called on a composite to its
2929
* implementation method.
30-
* <p />
30+
* <p>
3131
* {@link MethodPredicate Predicates} are ordered by filtering priority and applied individually. If a predicate does
3232
* not yield any positive match, the next predicate is applied.
3333
*

Diff for: src/main/java/org/springframework/data/repository/core/support/MethodLookups.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ static MethodLookup direct() {
6565

6666
/**
6767
* Repository type-aware method lookup composed of {@link #direct()} and {@link RepositoryAwareMethodLookup}.
68-
* <p/>
68+
* <p>
6969
* Repository-aware lookups resolve generic types from the repository declaration to verify assignability to Id/domain
7070
* types. This lookup also permits assignable method signatures but prefers {@link #direct()} matches.
7171
*
@@ -79,7 +79,7 @@ static MethodLookup forRepositoryTypes(RepositoryMetadata repositoryMetadata) {
7979

8080
/**
8181
* Repository type-aware method lookup composed of {@link #direct()} and {@link ReactiveTypeInteropMethodLookup}.
82-
* <p/>
82+
* <p>
8383
* This method lookup considers adaptability of reactive types in method signatures. Repository methods accepting a
8484
* reactive type can be possibly called with a different reactive type if the reactive type can be adopted to the
8585
* target type. This lookup also permits assignable method signatures and resolves repository id/entity types but

Diff for: src/main/java/org/springframework/data/repository/core/support/ReactiveRepositoryFactorySupport.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ protected void validate(RepositoryMetadata repositoryMetadata) {
6464
* queries.
6565
*
6666
* @param evaluationContextProvider can be {@literal null}, defaults to
67-
* {@link ReactiveQueryMethodEvaluationContextProvider#INSTANCE}.
67+
* {@link ReactiveQueryMethodEvaluationContextProvider#DEFAULT}.
6868
*/
6969
@Override
7070
public void setEvaluationContextProvider(QueryMethodEvaluationContextProvider evaluationContextProvider) {

0 commit comments

Comments
 (0)