Fix CS warnings in cds-access-api and enable enforcement
[controller.git] / opendaylight / md-sal / cds-access-api / src / main / java / org / opendaylight / controller / cluster / access / commands / LocalHistorySuccessProxyV1.java
index 23858b20b2221bb55b99b1477001329782fc0da1..97a7a1c8d6c7e991d4cf629a0ffbc432968c723d 100644 (file)
@@ -20,7 +20,10 @@ import org.opendaylight.controller.cluster.access.concepts.LocalHistoryIdentifie
 final class LocalHistorySuccessProxyV1 extends AbstractSuccessProxy<LocalHistoryIdentifier, LocalHistorySuccess> {
     private static final long serialVersionUID = 1L;
 
-    LocalHistorySuccessProxyV1() {
+    // checkstyle flags the public modifier as redundant however it is explicitly needed for Java serialization to
+    // be able to create instances via reflection.
+    @SuppressWarnings("checkstyle:RedundantModifier")
+    public LocalHistorySuccessProxyV1() {
         // For Externalizable
     }
 
@@ -29,7 +32,7 @@ final class LocalHistorySuccessProxyV1 extends AbstractSuccessProxy<LocalHistory
     }
 
     @Override
-    protected final LocalHistoryIdentifier readTarget(final DataInput in) throws IOException {
+    protected LocalHistoryIdentifier readTarget(final DataInput in) throws IOException {
         return LocalHistoryIdentifier.readFrom(in);
     }