Skip to content

Commit fe57fd2

Browse files
committed
Checkstyle changes
* Upgrade to Checkstyle 9.0 * apply some JavaDocs rules * Fix JavaDocs rules violations * Some other minor clean up in the affected classes
1 parent d2e23c5 commit fe57fd2

File tree

217 files changed

+734
-573
lines changed

Some content is hidden

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

217 files changed

+734
-573
lines changed

build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -343,7 +343,7 @@ configure(javaProjects) { subproject ->
343343

344344
checkstyle {
345345
configDirectory.set(rootProject.file('src/checkstyle'))
346-
toolVersion = project.hasProperty('checkstyleVersion') ? project.checkstyleVersion : '8.45.1'
346+
toolVersion = project.hasProperty('checkstyleVersion') ? project.checkstyleVersion : '9.0'
347347
}
348348

349349
jar {

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/channel/AbstractAmqpChannel.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -77,8 +77,8 @@ public abstract class AbstractAmqpChannel extends AbstractMessageChannel impleme
7777
* @param amqpTemplate the template.
7878
* @param outboundMapper the outbound mapper.
7979
* @param inboundMapper the inbound mapper.
80-
* @see #setExtractPayload(boolean)
8180
* @since 4.3
81+
* @see #setExtractPayload(boolean)
8282
*/
8383
AbstractAmqpChannel(AmqpTemplate amqpTemplate, AmqpHeaderMapper outboundMapper, AmqpHeaderMapper inboundMapper) {
8484
Assert.notNull(amqpTemplate, "amqpTemplate must not be null");
@@ -132,8 +132,8 @@ public void setExtractPayload(boolean extractPayload) {
132132

133133
/**
134134
* @return the extract payload.
135-
* @see #setExtractPayload(boolean)
136135
* @since 4.3
136+
* @see #setExtractPayload(boolean)
137137
*/
138138
protected boolean isExtractPayload() {
139139
return this.extractPayload;

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/channel/AbstractSubscribableAmqpChannel.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -87,8 +87,8 @@ protected AbstractSubscribableAmqpChannel(String channelName, AbstractMessageLis
8787
* @param amqpTemplate the template.
8888
* @param outboundMapper the outbound mapper.
8989
* @param inboundMapper the inbound mapper.
90-
* @see #setExtractPayload(boolean)
9190
* @since 4.3
91+
* @see #setExtractPayload(boolean)
9292
*/
9393
protected AbstractSubscribableAmqpChannel(String channelName, AbstractMessageListenerContainer container,
9494
AmqpTemplate amqpTemplate, AmqpHeaderMapper outboundMapper, AmqpHeaderMapper inboundMapper) {
@@ -120,8 +120,8 @@ protected AbstractSubscribableAmqpChannel(String channelName,
120120
* @param isPubSub true for a pub/sub channel.
121121
* @param outboundMapper the outbound mapper.
122122
* @param inboundMapper the inbound mapper.
123-
* @see #setExtractPayload(boolean)
124123
* @since 4.3
124+
* @see #setExtractPayload(boolean)
125125
*/
126126
protected AbstractSubscribableAmqpChannel(String channelName,
127127
AbstractMessageListenerContainer container,

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/channel/PointToPointSubscribableAmqpChannel.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -57,8 +57,8 @@ public PointToPointSubscribableAmqpChannel(String channelName, AbstractMessageLi
5757
* @param amqpTemplate the template.
5858
* @param outboundMapper the outbound mapper.
5959
* @param inboundMapper the inbound mapper.
60-
* @see #setExtractPayload(boolean)
6160
* @since 4.3
61+
* @see #setExtractPayload(boolean)
6262
*/
6363
public PointToPointSubscribableAmqpChannel(String channelName, AbstractMessageListenerContainer container,
6464
AmqpTemplate amqpTemplate, AmqpHeaderMapper outboundMapper, AmqpHeaderMapper inboundMapper) {

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/channel/PollableAmqpChannel.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -82,8 +82,8 @@ public PollableAmqpChannel(String channelName, AmqpTemplate amqpTemplate) {
8282
* @param amqpTemplate the template.
8383
* @param outboundMapper the outbound mapper.
8484
* @param inboundMapper the inbound mapper.
85-
* @see #setExtractPayload(boolean)
8685
* @since 4.3
86+
* @see #setExtractPayload(boolean)
8787
*/
8888
public PollableAmqpChannel(String channelName, AmqpTemplate amqpTemplate, AmqpHeaderMapper outboundMapper,
8989
AmqpHeaderMapper inboundMapper) {

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/channel/PublishSubscribeAmqpChannel.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -68,8 +68,8 @@ public PublishSubscribeAmqpChannel(String channelName, AbstractMessageListenerCo
6868
* @param amqpTemplate the template
6969
* @param outboundMapper the outbound mapper.
7070
* @param inboundMapper the inbound mapper.
71-
* @see #setExtractPayload(boolean)
7271
* @since 4.3
72+
* @see #setExtractPayload(boolean)
7373
*/
7474
public PublishSubscribeAmqpChannel(String channelName, AbstractMessageListenerContainer container,
7575
AmqpTemplate amqpTemplate, AmqpHeaderMapper outboundMapper, AmqpHeaderMapper inboundMapper) {

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/dsl/AbstractMessageListenerContainerSpec.java

+4-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2017-2019 the original author or authors.
2+
* Copyright 2017-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -37,6 +37,9 @@
3737
/**
3838
* Base class for container specs.
3939
*
40+
* @param <S> the current spec extension type
41+
* @param <C> the listener container type
42+
*
4043
* @author Gary Russell
4144
* @author Artem Bilan
4245
*

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/dsl/Amqp.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2014-2020 the original author or authors.
2+
* Copyright 2014-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -155,7 +155,7 @@ public static AmqpInboundGatewayDMLCSpec inboundGateway(DirectMessageListenerCon
155155
}
156156

157157
/**
158-
* Create an initial AmqpInboundPolledChannelAdapterSpec
158+
* Create an initial AmqpInboundPolledChannelAdapterSpec.
159159
* @param connectionFactory the connectionFactory.
160160
* @param queue the queue.
161161
* @return the AmqpInboundPolledChannelAdapterSpec.
@@ -168,7 +168,7 @@ public static AmqpInboundPolledChannelAdapterSpec inboundPolledAdapter(Connectio
168168
}
169169

170170
/**
171-
* Create an initial AmqpInboundPolledChannelAdapterSpec
171+
* Create an initial AmqpInboundPolledChannelAdapterSpec.
172172
* @param connectionFactory the connectionFactory.
173173
* @param ackCallbackFactory the ackCallbackFactory
174174
* @param queue the queue.

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/dsl/AmqpMessageChannelSpec.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2014-2020 the original author or authors.
2+
* Copyright 2014-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -36,6 +36,7 @@
3636
* {@link org.springframework.integration.amqp.channel.PointToPointSubscribableAmqpChannel}.
3737
*
3838
* @param <S> the target {@link AmqpMessageChannelSpec} implementation type.
39+
* @param <T> the target channel type.
3940
*
4041
* @author Artem Bilan
4142
* @author Gary Russell

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/dsl/AmqpOutboundChannelAdapterSpec.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2020 the original author or authors.
2+
* Copyright 2020-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -19,7 +19,7 @@
1919
import org.springframework.amqp.core.AmqpTemplate;
2020

2121
/**
22-
* Spec for an outbound AMQP channel adapter
22+
* Spec for an outbound AMQP channel adapter.
2323
*
2424
* @author Gary Russell
2525
* @author Artme Bilan

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/dsl/AmqpPollableMessageChannelSpec.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2014-2020 the original author or authors.
2+
* Copyright 2014-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -33,6 +33,7 @@
3333
* A {@link MessageChannelSpec} for a {@link AbstractAmqpChannel}s.
3434
*
3535
* @param <S> the target {@link AmqpPollableMessageChannelSpec} implementation type.
36+
* @param <T> the target channel type.
3637
*
3738
* @author Artem Bilan
3839
* @author Gary Russell

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/dsl/SimpleMessageListenerContainerSpec.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2017-2020 the original author or authors.
2+
* Copyright 2017-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -111,8 +111,8 @@ public SimpleMessageListenerContainerSpec receiveTimeout(long receiveTimeout) {
111111
* The batch size to use.
112112
* @param batchSize the batchSize.
113113
* @return the spec.
114-
* @see SimpleMessageListenerContainer#setBatchSize(int)
115114
* @since 5.2
115+
* @see SimpleMessageListenerContainer#setBatchSize(int)
116116
*/
117117
public SimpleMessageListenerContainerSpec batchSize(int batchSize) {
118118
this.listenerContainer.setBatchSize(batchSize);

spring-integration-amqp/src/main/java/org/springframework/integration/amqp/support/DefaultAmqpHeaderMapper.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -340,9 +340,9 @@ private void addConsumerMetadata(MessageProperties messageProperties, Map<String
340340
/**
341341
* Construct a default inbound header mapper.
342342
* @return the mapper.
343+
* @since 4.3
343344
* @see #inboundRequestHeaders()
344345
* @see #inboundReplyHeaders()
345-
* @since 4.3
346346
*/
347347
public static DefaultAmqpHeaderMapper inboundMapper() {
348348
return new DefaultAmqpHeaderMapper(inboundRequestHeaders(), inboundReplyHeaders());
@@ -351,9 +351,9 @@ public static DefaultAmqpHeaderMapper inboundMapper() {
351351
/**
352352
* Construct a default outbound header mapper.
353353
* @return the mapper.
354+
* @since 4.3
354355
* @see #outboundRequestHeaders()
355356
* @see #outboundReplyHeaders()
356-
* @since 4.3
357357
*/
358358
public static DefaultAmqpHeaderMapper outboundMapper() {
359359
return new DefaultAmqpHeaderMapper(outboundRequestHeaders(), outboundReplyHeaders());

spring-integration-core/src/main/java/org/springframework/integration/aggregator/CorrelatingMessageBarrier.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ public CorrelatingMessageBarrier(MessageGroupStore store) {
7373

7474

7575
/**
76-
* Set the CorrelationStrategy to be used to determine the correlation key for incoming messages
76+
* Set the CorrelationStrategy to be used to determine the correlation key for incoming messages.
7777
* @param correlationStrategy The correlation strategy.
7878
*/
7979
public void setCorrelationStrategy(CorrelationStrategy correlationStrategy) {

spring-integration-core/src/main/java/org/springframework/integration/aggregator/MethodInvokingMessageListProcessor.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -31,6 +31,8 @@
3131
/**
3232
* A MessageListProcessor implementation that invokes a method on a target POJO.
3333
*
34+
* @param <T> the method evaluation expecetd result type.
35+
*
3436
* @author Dave Syer
3537
* @author Artem Bilan
3638
* @author Gary Russell

spring-integration-core/src/main/java/org/springframework/integration/aggregator/ResequencingMessageHandler.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -57,7 +57,7 @@ public ResequencingMessageHandler(MessageGroupProcessor processor) {
5757

5858
/**
5959
* Overridden to false for a resequencer so late messages are immediately discarded rather
60-
* than waiting for the next timeout
60+
* than waiting for the next timeout.
6161
*/
6262
@Override
6363
public final void setExpireGroupsUponTimeout(boolean expireGroupsUponTimeout) {

spring-integration-core/src/main/java/org/springframework/integration/annotation/Router.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@
6767
String defaultOutputChannel() default "";
6868

6969
/**
70-
* The 'key=value' pairs to represent channelMapping entries
70+
* The 'key=value' pairs to represent channelMapping entries.
7171
* @return the channelMappings.
7272
* @see org.springframework.integration.router.AbstractMappingMessageRouter#setChannelMapping(String, String)
7373
*/

spring-integration-core/src/main/java/org/springframework/integration/channel/DirectChannel.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -40,7 +40,7 @@ public class DirectChannel extends AbstractSubscribableChannel {
4040
private volatile Integer maxSubscribers;
4141

4242
/**
43-
* Create a channel with default {@link RoundRobinLoadBalancingStrategy}
43+
* Create a channel with default {@link RoundRobinLoadBalancingStrategy}.
4444
*/
4545
public DirectChannel() {
4646
this(new RoundRobinLoadBalancingStrategy());

spring-integration-core/src/main/java/org/springframework/integration/channel/PriorityChannel.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2020 the original author or authors.
2+
* Copyright 2002-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -40,7 +40,7 @@
4040
public class PriorityChannel extends QueueChannel {
4141

4242
/**
43-
* PriorityBlockingQueue#DEFAULT_INITIAL_CAPACITY is private
43+
* PriorityBlockingQueue#DEFAULT_INITIAL_CAPACITY is private.
4444
*/
4545
private static final int DEFAULT_INITIAL_CAPACITY = 11;
4646

spring-integration-core/src/main/java/org/springframework/integration/codec/Codec.java

+5-5
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2015-2019 the original author or authors.
2+
* Copyright 2015-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -28,23 +28,23 @@
2828
*/
2929
public interface Codec {
3030
/**
31-
* Encode (encode) an object to an OutputStream
31+
* Encode (encode) an object to an OutputStream.
3232
* @param object the object to encode
3333
* @param outputStream the OutputStream
3434
* @throws IOException if the operation fails
3535
*/
3636
void encode(Object object, OutputStream outputStream) throws IOException;
3737

3838
/**
39-
* Encode an object to a byte array
39+
* Encode an object to a byte array.
4040
* @param object the object to encode
4141
* @return the bytes
4242
* @throws IOException if the operation fails
4343
*/
4444
byte[] encode(Object object) throws IOException;
4545

4646
/**
47-
* Decode an object of a given type
47+
* Decode an object of a given type.
4848
* @param inputStream the input stream containing the encoded object
4949
* @param type the object's class
5050
* @param <T> the object's type
@@ -54,7 +54,7 @@ public interface Codec {
5454
<T> T decode(InputStream inputStream, Class<T> type) throws IOException;
5555

5656
/**
57-
* Decode an object of a given type
57+
* Decode an object of a given type.
5858
* @param bytes the byte array containing the encoded object
5959
* @param type the object's class
6060
* @param <T> the object's type

spring-integration-core/src/main/java/org/springframework/integration/codec/CodecMessageConverter.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2015-2019 the original author or authors.
2+
* Copyright 2015-2021 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -28,9 +28,10 @@
2828
import org.springframework.util.Assert;
2929

3030
/**
31-
* A {@link MessageConverter} that delegates to a {@link Codec} to convert
31+
* A {@link MessageConverter} that delegates to a {@link Codec} to convert.
3232
*
3333
* @author Gary Russell
34+
*
3435
* @since 4.2
3536
*
3637
*/

0 commit comments

Comments
 (0)