Skip to content

Commit 00e1e68

Browse files
committed
Mark private classes final
See gh-1479
1 parent 360f523 commit 00e1e68

File tree

48 files changed

+70
-69
lines changed

Some content is hidden

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

48 files changed

+70
-69
lines changed

spring-ws-core/src/main/java/org/springframework/ws/client/core/WebServiceTemplate.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -852,7 +852,8 @@ protected Object handleFault(WebServiceConnection connection, MessageContext mes
852852
* Adapter to enable use of a WebServiceMessageCallback inside a
853853
* WebServiceMessageExtractor.
854854
*/
855-
private static class WebServiceMessageCallbackMessageExtractor implements WebServiceMessageExtractor<Boolean> {
855+
private static final class WebServiceMessageCallbackMessageExtractor
856+
implements WebServiceMessageExtractor<Boolean> {
856857

857858
private final WebServiceMessageCallback callback;
858859

@@ -869,7 +870,7 @@ public Boolean extractData(WebServiceMessage message) throws IOException, Transf
869870
}
870871

871872
/** Adapter to enable use of a SourceExtractor inside a WebServiceMessageExtractor. */
872-
private static class SourceExtractorMessageExtractor<T> implements WebServiceMessageExtractor<T> {
873+
private static final class SourceExtractorMessageExtractor<T> implements WebServiceMessageExtractor<T> {
873874

874875
private final SourceExtractor<T> sourceExtractor;
875876

spring-ws-core/src/main/java/org/springframework/ws/config/annotation/DelegatingWsConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ protected void addReturnValueHandlers(List<MethodReturnValueHandler> returnValue
6969
this.configurers.addReturnValueHandlers(returnValueHandlers);
7070
}
7171

72-
private static class WsConfigurers implements WsConfigurer {
72+
private static final class WsConfigurers implements WsConfigurer {
7373

7474
private final Supplier<Stream<WsConfigurer>> delegates;
7575

spring-ws-core/src/main/java/org/springframework/ws/mime/AbstractMimeMessage.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ public final Attachment addAttachment(String contentId, InputStreamSource inputS
6565
* @author Arjen Poutsma
6666
* @since 1.0.0
6767
*/
68-
private static class InputStreamSourceDataSource implements DataSource {
68+
private static final class InputStreamSourceDataSource implements DataSource {
6969

7070
private final InputStreamSource inputStreamSource;
7171

spring-ws-core/src/main/java/org/springframework/ws/server/endpoint/AbstractStaxEventPayloadEndpoint.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ protected abstract void invokeInternal(XMLEventReader eventReader, XMLEventConsu
151151
* {@code WebServiceMessage} as soon as any method is called, thus lazily creating the
152152
* response.
153153
*/
154-
private class ResponseCreatingEventWriter implements XMLEventWriter {
154+
private final class ResponseCreatingEventWriter implements XMLEventWriter {
155155

156156
private XMLEventWriter eventWriter;
157157

spring-ws-core/src/main/java/org/springframework/ws/server/endpoint/AbstractStaxStreamPayloadEndpoint.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ private XMLStreamWriter getStreamWriter(Result result) {
126126
* {@code WebServiceMessage} as soon as any method is called, thus lazily creating the
127127
* response.
128128
*/
129-
private class ResponseCreatingStreamWriter implements XMLStreamWriter {
129+
private final class ResponseCreatingStreamWriter implements XMLStreamWriter {
130130

131131
private MessageContext messageContext;
132132

spring-ws-core/src/main/java/org/springframework/ws/server/endpoint/AbstractXomPayloadEndpoint.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ protected Serializer createSerializer(OutputStream outputStream) {
116116
*/
117117
protected abstract Element invokeInternal(Element requestElement) throws Exception;
118118

119-
private static class XomSourceCallback implements TraxUtils.SourceCallback {
119+
private static final class XomSourceCallback implements TraxUtils.SourceCallback {
120120

121121
private Element element;
122122

@@ -206,15 +206,15 @@ public void source(String systemId) throws Exception {
206206
}
207207

208208
@SuppressWarnings("serial")
209-
private static class XomParsingException extends NestedRuntimeException {
209+
private static final class XomParsingException extends NestedRuntimeException {
210210

211211
private XomParsingException(ParsingException ex) {
212212
super(ex.getMessage(), ex);
213213
}
214214

215215
}
216216

217-
private static class StaxStreamConverter {
217+
private static final class StaxStreamConverter {
218218

219219
private static Document convert(XMLStreamReader streamReader) throws XMLStreamException {
220220
NodeFactory nodeFactory = new NodeFactory();

spring-ws-core/src/main/java/org/springframework/ws/server/endpoint/adapter/method/SourcePayloadMethodProcessor.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ protected XMLInputFactory createXmlInputFactory() {
129129
}
130130

131131
/** Inner class to avoid a static JAXP 1.4 dependency. */
132-
private static class Jaxp14StaxHandler {
132+
private static final class Jaxp14StaxHandler {
133133

134134
private static boolean isStaxSource(Class<?> clazz) {
135135
return StAXSource.class.isAssignableFrom(clazz);
@@ -141,7 +141,7 @@ private static Source createStaxSource(XMLStreamReader streamReader, String syst
141141

142142
}
143143

144-
private static class SystemIdStreamReaderDelegate extends StreamReaderDelegate {
144+
private static final class SystemIdStreamReaderDelegate extends StreamReaderDelegate {
145145

146146
private final String systemId;
147147

spring-ws-core/src/main/java/org/springframework/ws/server/endpoint/adapter/method/jaxb/AbstractJaxb2PayloadMethodProcessor.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,7 @@ private JAXBContext getJaxbContext(Class<?> clazz) throws JAXBException {
233233

234234
// Callbacks
235235

236-
private class Jaxb2SourceCallback implements TraxUtils.SourceCallback {
236+
private final class Jaxb2SourceCallback implements TraxUtils.SourceCallback {
237237

238238
private final Unmarshaller unmarshaller;
239239

@@ -301,7 +301,7 @@ public void source(String systemId) throws Exception {
301301

302302
}
303303

304-
private class JaxbElementSourceCallback<T> implements TraxUtils.SourceCallback {
304+
private final class JaxbElementSourceCallback<T> implements TraxUtils.SourceCallback {
305305

306306
private final Unmarshaller unmarshaller;
307307

@@ -351,7 +351,7 @@ public void source(String systemId) throws Exception {
351351

352352
}
353353

354-
private class Jaxb2ResultCallback implements TraxUtils.ResultCallback {
354+
private final class Jaxb2ResultCallback implements TraxUtils.ResultCallback {
355355

356356
private final Marshaller marshaller;
357357

@@ -399,7 +399,7 @@ public void result(String systemId) throws Exception {
399399

400400
}
401401

402-
private class JaxbStreamingPayload implements StreamingPayload {
402+
private final class JaxbStreamingPayload implements StreamingPayload {
403403

404404
private final Object jaxbElement;
405405

spring-ws-core/src/main/java/org/springframework/ws/server/endpoint/support/PayloadRootUtils.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ public static QName getPayloadRootQName(Source source, TransformerHelper transfo
8989
}
9090
}
9191

92-
private static class PayloadRootSourceCallback implements TraxUtils.SourceCallback {
92+
private static final class PayloadRootSourceCallback implements TraxUtils.SourceCallback {
9393

9494
private QName result;
9595

spring-ws-core/src/main/java/org/springframework/ws/soap/saaj/SaajSoapFaultDetail.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ protected Detail getSaajDetail() {
7171
return (Detail) getSaajElement();
7272
}
7373

74-
private static class SaajSoapFaultDetailElementIterator implements Iterator<SoapFaultDetailElement> {
74+
private static final class SaajSoapFaultDetailElementIterator implements Iterator<SoapFaultDetailElement> {
7575

7676
private final Iterator<DetailEntry> iterator;
7777

0 commit comments

Comments
 (0)