Fix checkstyle warnings for impl/protocol test package 73/62273/2
authormiroslav.macko <miroslav.macko@pantheon.tech>
Thu, 24 Aug 2017 13:22:41 +0000 (15:22 +0200)
committerMiroslav Macko <miroslav.macko@pantheon.tech>
Fri, 25 Aug 2017 07:19:57 +0000 (07:19 +0000)
See also: bug 8607

Change-Id: Icd8914faf38d0d6493dbe633b93cd2442e0bdfd4
Signed-off-by: miroslav.macko <miroslav.macko@pantheon.tech>
86 files changed:
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/AbstractDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/MessageDeserializerInjectorTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/AbstractActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/CopyTtlInActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/CopyTtlOutActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/DecMplsTtlActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/DecNwTtlActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/GroupActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/OutputActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/PopMplsActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/PopPbbActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/PopVlanActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/PushMplsActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/PushPbbActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/PushVlanActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/SetFieldActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/SetMplsTtlActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/SetNwTtlActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/action/SetQueueActionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/AbstractInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/ApplyActionsInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/ClearActionsInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/GoToTableInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/MeterInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/WriteActionsInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/instruction/WriteMetadataInstructionDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/AbstractMatchEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/ArpSourceHardwareAddressEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/ArpTargetHardwareAddressEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/EthernetDestinationEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/EthernetSourceEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/Ipv4DestinationEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/Ipv4SourceEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/Ipv6NdTargetEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/MplsBosEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/MplsLabelEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/MplsTcEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/PbbEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/SctpDestinationPortEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/SctpSourcePortEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/TcpDestinationPortEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/TcpFlagsEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/TcpSourcePortEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/TunnelIdEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/UdpDestinationPortEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/UdpSourcePortEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/match/VlanVidEntryDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/messages/FlowMessageDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/messages/GroupMessageDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/messages/PacketInMessageDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyFlowAggregateStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyFlowStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyFlowTableStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyGroupDescDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyGroupFeaturesDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyGroupStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyMessageDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyMeterFeaturesDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyMeterStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyPortDescDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyPortStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyQueueStatsDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/deserialization/multipart/MultipartReplyTableFeaturesDeserializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/AbstractSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/InstructionSerializerInjectorTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/MessageSerializerInjectorTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/actions/AbstractActionSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/instructions/AbstractInstructionSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/AbstractExperimenterMatchEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/AbstractMatchEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/Ipv6DestinationEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/Ipv6NdSllEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/Ipv6NdTllEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/Ipv6SourceEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/match/VlanVidEntrySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/messages/FlowMessageSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/messages/GroupMessageSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/messages/MeterMessageSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/messages/PortMessageSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/MultipartRequestMessageSerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/tablefeatures/AbstractTablePropertySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/tablefeatures/ApplyActionsMissTablePropertySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/tablefeatures/ApplySetfieldMissTablePropertySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/tablefeatures/InstructionsMissTablePropertySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/tablefeatures/WriteActionsMissTablePropertySerializerTest.java
openflowplugin-impl/src/test/java/org/opendaylight/openflowplugin/impl/protocol/serialization/multipart/tablefeatures/WriteSetfieldMissTablePropertySerializerTest.java

index 0555537ec709403658937bf117959b1e378296d3..6d15944550bd2b9202f51a69ecf78fd2d01688ee 100644 (file)
@@ -70,7 +70,7 @@ public abstract class AbstractDeserializerTest {
         private final DeserializerRegistry registry;
         private final DeserializationFactory factory;
 
-        public DeserializerExtensionProviderImpl(final DeserializerRegistry registry, DeserializationFactory factory) {
+        DeserializerExtensionProviderImpl(final DeserializerRegistry registry, DeserializationFactory factory) {
             this.registry = registry;
             this.factory = factory;
         }
@@ -86,53 +86,62 @@ public abstract class AbstractDeserializerTest {
         }
 
         @Override
-        public void registerActionDeserializer(ExperimenterActionDeserializerKey key, OFGeneralDeserializer deserializer) {
+        public void registerActionDeserializer(ExperimenterActionDeserializerKey key,
+                                               OFGeneralDeserializer deserializer) {
 
         }
 
         @Override
-        public void registerInstructionDeserializer(ExperimenterInstructionDeserializerKey key, OFGeneralDeserializer deserializer) {
+        public void registerInstructionDeserializer(ExperimenterInstructionDeserializerKey key,
+                                                    OFGeneralDeserializer deserializer) {
 
         }
 
         @Override
-        public void registerMatchEntryDeserializer(MatchEntryDeserializerKey key, OFGeneralDeserializer deserializer) {
+        public void registerMatchEntryDeserializer(MatchEntryDeserializerKey key,
+                                                   OFGeneralDeserializer deserializer) {
 
         }
 
         @Override
-        public void registerErrorDeserializer(ExperimenterIdDeserializerKey key, OFDeserializer<ErrorMessage> deserializer) {
+        public void registerErrorDeserializer(ExperimenterIdDeserializerKey key,
+                                              OFDeserializer<ErrorMessage> deserializer) {
 
         }
 
         @Override
-        public void registerExperimenterMessageDeserializer(ExperimenterIdDeserializerKey key, OFDeserializer<? extends ExperimenterDataOfChoice> deserializer) {
+        public void registerExperimenterMessageDeserializer(ExperimenterIdDeserializerKey key,
+                                                    OFDeserializer<? extends ExperimenterDataOfChoice> deserializer) {
 
         }
 
         @Override
-        public void registerMultipartReplyMessageDeserializer(ExperimenterIdDeserializerKey key, OFDeserializer<? extends ExperimenterDataOfChoice> deserializer) {
+        public void registerMultipartReplyMessageDeserializer(ExperimenterIdDeserializerKey key,
+                                                      OFDeserializer<? extends ExperimenterDataOfChoice> deserializer) {
 
         }
 
         @Override
-        public void registerMultipartReplyTFDeserializer(ExperimenterIdDeserializerKey key, OFGeneralDeserializer deserializer) {
+        public void registerMultipartReplyTFDeserializer(ExperimenterIdDeserializerKey key,
+                                                         OFGeneralDeserializer deserializer) {
 
         }
 
         @Override
-        public void registerMeterBandDeserializer(ExperimenterIdDeserializerKey key, OFDeserializer<MeterBandExperimenterCase> deserializer) {
+        public void registerMeterBandDeserializer(ExperimenterIdDeserializerKey key,
+                                                  OFDeserializer<MeterBandExperimenterCase> deserializer) {
 
         }
 
         @Override
-        public void registerQueuePropertyDeserializer(ExperimenterIdDeserializerKey key, OFDeserializer<QueueProperty> deserializer) {
+        public void registerQueuePropertyDeserializer(ExperimenterIdDeserializerKey key,
+                                                      OFDeserializer<QueueProperty> deserializer) {
 
         }
 
         @Override
-        public void registerDeserializerMapping(TypeToClassKey typeToClassKey, Class<?> aClass) {
-            factory.registerMapping(typeToClassKey, aClass);
+        public void registerDeserializerMapping(TypeToClassKey typeToClassKey, Class<?> clazz) {
+            factory.registerMapping(typeToClassKey, clazz);
         }
 
         @Override
index 1ad7eafb74e24fedb45b185d25214b2e95679a4a..c63720d052ec19fbfc37db30dd7189c540912455 100644 (file)
@@ -32,19 +32,24 @@ public class MessageDeserializerInjectorTest {
     @Mock
     private OFDeserializer<OfHeader> ofDeserializer;
 
-    private Function<Integer, Function<Class<? extends OfHeader>, Consumer<OFDeserializer<? extends OfHeader>>>> injector;
+    private Function<Integer, Function<Class<? extends OfHeader>, Consumer<OFDeserializer<? extends OfHeader>>>>
+            injector;
 
     @Before
     public void setUp() throws Exception {
-        injector = MessageDeserializerInjector.createInjector(switchConnectionProvider, EncodeConstants.OF13_VERSION_ID);
+        injector = MessageDeserializerInjector.createInjector(switchConnectionProvider, EncodeConstants
+                .OF13_VERSION_ID);
     }
 
     @Test
     public void injectDeserializers() throws Exception {
         injector.apply(10).apply(OfHeader.class).accept(ofDeserializer);
-        verify(switchConnectionProvider).unregisterDeserializerMapping(new TypeToClassKey(EncodeConstants.OF13_VERSION_ID, 10));
-        verify(switchConnectionProvider).registerDeserializerMapping(new TypeToClassKey(EncodeConstants.OF13_VERSION_ID, 10), OfHeader.class);
-        verify(switchConnectionProvider).registerDeserializer(new MessageCodeKey(EncodeConstants.OF13_VERSION_ID, 10, OfHeader.class), ofDeserializer);
+        verify(switchConnectionProvider).unregisterDeserializerMapping(new TypeToClassKey(EncodeConstants
+                .OF13_VERSION_ID, 10));
+        verify(switchConnectionProvider).registerDeserializerMapping(new TypeToClassKey(EncodeConstants
+                .OF13_VERSION_ID, 10), OfHeader.class);
+        verify(switchConnectionProvider).registerDeserializer(new MessageCodeKey(EncodeConstants.OF13_VERSION_ID, 10,
+                OfHeader.class), ofDeserializer);
     }
 
 }
\ No newline at end of file
index 216fd04e1ce3bd5e032528d3fd7a51135c6e5608..fffe678e77c6036a170ea7bf0ec3a6146482a431 100644 (file)
@@ -9,7 +9,6 @@
 package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 
 import io.netty.buffer.ByteBuf;
-
 import org.opendaylight.openflowjava.protocol.api.extensibility.OFDeserializer;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowplugin.api.openflow.protocol.deserialization.MessageCodeExperimenterKey;
@@ -36,6 +35,7 @@ public abstract class AbstractActionDeserializerTest extends AbstractDeserialize
     }
 
     protected abstract short getType();
+
     protected abstract short getLength();
 
 }
index 395559d786c398757c1aa1edfeaca9a4de27661a..a50f1f1480b20799cce4efa3ce4c527364d2fb0a 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.CopyTtlInCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class CopyTtlInActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 71d1e1384b02968d107c2df7b2678f700741e811..25544f8f526dbcb6ea9db9506c15b4942294817d 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.CopyTtlOutCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class CopyTtlOutActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 5282be02854febaf9794b6595d4d556da90717dc..13a8eae5e6ec56e0f94999824803cecd7aa44d9e 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.DecMplsTtlCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class DecMplsTtlActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index dacaf003ef0ddb0724d38a562d4051512290b76f..cd1141be22d5b111faf3e5ee86f30a4588c4a1d0 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.DecNwTtlCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class DecNwTtlActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 5282cff6eb8d82c4836a004bba1905f4446fd028..e0b71cc85dab452ccaad3b9f4f7b535b78b48df9 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.GroupActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class GroupActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index f20cfa281e56862df9e9df37d4cfb597f965b245..0eb2eb780e1c587017c2b51ace7172df404f6547 100644 (file)
@@ -11,6 +11,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.openflowplugin.api.openflow.md.util.OpenflowVersion;
@@ -19,9 +21,6 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.acti
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.OutputActionCase;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.output.action._case.OutputAction;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class OutputActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
@@ -39,7 +38,7 @@ public class OutputActionDeserializerTest extends AbstractActionDeserializerTest
 
         final OutputAction outputAction = OutputActionCase.class.cast(action).getOutputAction();
         assertEquals(portNum, InventoryDataServiceUtil.portNumberfromNodeConnectorId(
-                    OpenflowVersion.OF13, outputAction.getOutputNodeConnector().getValue()).intValue());
+                OpenflowVersion.OF13, outputAction.getOutputNodeConnector().getValue()).intValue());
         assertEquals(maxLength, outputAction.getMaxLength().shortValue());
         assertEquals(0, in.readableBytes());
     }
index ca5287d1d9f9c578ca12eda17c488ad0c3749318..b25ed21f47ad1e4a24e755d3b8408b0ed0b6cf4b 100644 (file)
@@ -11,15 +11,14 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.PopMplsActionCase;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.pop.mpls.action._case.PopMplsAction;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PopMplsActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 40ee87583f72d6247707333ca6bdecc97ea12c6f..e7f526326b9d4d421cf010515c6b927d9e515102 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.PopPbbActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PopPbbActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 5bd30db9621e6b67e8c312ff777913834365cbd1..c64334fa6d311b7425a87cd3c870f585aa662d64 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.PopVlanActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PopVlanActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 5e075afc2ae2f2968a32afdf1c51685565738652..0b29e1ea2bc5c14aa6b07542387d27ebcbc7b8f6 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.PushMplsActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PushMplsActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 97b36f5a4807dbbeb4ba7ffc12a4fdb3da1f3b6f..f3627b047cfaa694b54266640c9f813eacd77e59 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.PushPbbActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PushPbbActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 7c5e65d026175f52ae78812a16cf4c5b5992a5d5..9854425426bc55adcfb25f187e1813102186d98f 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.PushVlanActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PushVlanActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 4155c950992af81a5643d653a7aafdc6dae90c61..644aef2e40984e2af3a69ad40b21416ac05c9936 100644 (file)
@@ -11,6 +11,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.BinContent;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
@@ -20,9 +22,6 @@ import org.opendaylight.openflowplugin.openflow.md.util.OpenflowPortsUtil;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.SetFieldCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class SetFieldActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
@@ -39,7 +38,8 @@ public class SetFieldActionDeserializerTest extends AbstractActionDeserializerTe
         final Action action = deserializeAction(in);
         assertTrue(SetFieldCase.class.isInstance(action));
         assertEquals(
-                OpenflowPortsUtil.getPortLogicalName(EncodeConstants.OF13_VERSION_ID, BinContent.intToUnsignedLong(portNum)),
+                OpenflowPortsUtil
+                        .getPortLogicalName(EncodeConstants.OF13_VERSION_ID, BinContent.intToUnsignedLong(portNum)),
                 SetFieldCase.class.cast(action).getSetField().getInPort().getValue());
         assertEquals(0, in.readableBytes());
     }
index 2b4dfa61bea22f159434b8d1c8ed4128a6253b58..60f03194fd888807b4027ccd6f35d27abfdc2099 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.SetMplsTtlActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class SetMplsTtlActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 95138ea1383f2830e0a08c439794182ae4045aa0..598fe00a8ab0a434349a56f7c431f5b0d245e92e 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.SetNwTtlActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class SetNwTtlActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index 5fe9c8844a27f5627071963203577607bf3808c4..70f26f9ad63bfc0560edc2af6e61e0220925bb3b 100644 (file)
@@ -11,14 +11,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.action;
 import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertTrue;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.Action;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.action.action.SetQueueActionCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class SetQueueActionDeserializerTest extends AbstractActionDeserializerTest {
 
     @Test
index fc21cb044e7b63ac654e925223c73707466e3a97..37330603a4b43a8f844382df686ab7827a6d500d 100644 (file)
@@ -9,7 +9,6 @@
 package org.opendaylight.openflowplugin.impl.protocol.deserialization.instruction;
 
 import io.netty.buffer.ByteBuf;
-
 import org.opendaylight.openflowjava.protocol.api.extensibility.OFDeserializer;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowplugin.api.openflow.protocol.deserialization.MessageCodeExperimenterKey;
@@ -36,6 +35,7 @@ public abstract class AbstractInstructionDeserializerTest extends AbstractDeseri
     }
 
     protected abstract short getType();
+
     protected abstract short getLength();
 
 }
index 3db2597af2436999e97d1772078591f27b4e0877..3268c4f4ff0c3581f357a45ba9729bcafbe9b94d 100644 (file)
@@ -10,6 +10,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.instructio
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.extensibility.OFDeserializer;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
@@ -21,19 +23,18 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.acti
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.Instruction;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.ApplyActionsCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class ApplyActionsInstructionDeserializerTest extends AbstractInstructionDeserializerTest {
 
     private OFDeserializer<Instruction> deserializer;
 
     @Override
+    @SuppressWarnings("checkstyle:LineLength")
     protected void init() {
         deserializer = getRegistry().getDeserializer(
                 new MessageCodeActionExperimenterKey(EncodeConstants.OF13_VERSION_ID, getType(), Instruction.class,
-                    ActionPath.NODES_NODE_TABLE_FLOW_INSTRUCTIONS_INSTRUCTION_APPLYACTIONSCASE_APPLYACTIONS_ACTION_ACTION_EXTENSIONLIST_EXTENSION,
-                    null));
+                        ActionPath
+                                .NODES_NODE_TABLE_FLOW_INSTRUCTIONS_INSTRUCTION_APPLYACTIONSCASE_APPLYACTIONS_ACTION_ACTION_EXTENSIONLIST_EXTENSION,
+                        null));
     }
 
     @Test
index ad4067ab499670e2b085c68c36e2e58f2262424a..c878af29a159fad97c40b28f51a1bf28f1a2037b 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.instructio
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.InstructionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.Instruction;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.ClearActionsCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class ClearActionsInstructionDeserializerTest extends AbstractInstructionDeserializerTest {
 
     @Test
index a905a92284583e362289d36bb5653952a088820c..09a2c2957038f016a160ab5147759e2b7f1108cd 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.instructio
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.InstructionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.Instruction;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.GoToTableCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class GoToTableInstructionDeserializerTest extends AbstractInstructionDeserializerTest {
 
     @Test
index efce9573ba7f85a7e775fa5f3d089787ef2df229..5255fca155da88340cbdaa8d633e773639719bad 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.instructio
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.impl.util.InstructionConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.Instruction;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.MeterCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class MeterInstructionDeserializerTest extends AbstractInstructionDeserializerTest {
 
     @Test
index 8998a1c34764ca43af1e7aa6d6522c5f19d951fa..1403efc9ab23948910af3540795f7aed34cfc283 100644 (file)
@@ -10,6 +10,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.instructio
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.extensibility.OFDeserializer;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
@@ -21,19 +23,18 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.action.types.rev131112.acti
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.Instruction;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.WriteActionsCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class WriteActionsInstructionDeserializerTest extends AbstractInstructionDeserializerTest {
 
     private OFDeserializer<Instruction> deserializer;
 
     @Override
+    @SuppressWarnings("checkstyle:LineLength")
     protected void init() {
         deserializer = getRegistry().getDeserializer(
                 new MessageCodeActionExperimenterKey(EncodeConstants.OF13_VERSION_ID, getType(), Instruction.class,
-                    ActionPath.NODES_NODE_TABLE_FLOW_INSTRUCTIONS_INSTRUCTION_WRITEACTIONSCASE_WRITEACTIONS_ACTION_ACTION_EXTENSIONLIST_EXTENSION,
-                    null));
+                        ActionPath
+                                .NODES_NODE_TABLE_FLOW_INSTRUCTIONS_INSTRUCTION_WRITEACTIONSCASE_WRITEACTIONS_ACTION_ACTION_EXTENSIONLIST_EXTENSION,
+                        null));
     }
 
     @Test
index 5d435d778ccb0394df81b15515efb10d3dd06746..2b1bec2ffa1ca3b16e7653f06545a1d0b6bb2adb 100644 (file)
@@ -8,11 +8,12 @@
 
 package org.opendaylight.openflowplugin.impl.protocol.deserialization.instruction;
 
-import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import java.math.BigInteger;
-
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.impl.util.InstructionConstants;
@@ -20,9 +21,6 @@ import org.opendaylight.openflowplugin.openflow.md.util.ByteUtil;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.Instruction;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.WriteMetadataCase;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class WriteMetadataInstructionDeserializerTest extends AbstractInstructionDeserializerTest {
 
     @Test
@@ -39,16 +37,18 @@ public class WriteMetadataInstructionDeserializerTest extends AbstractInstructio
         assertEquals(WriteMetadataCase.class, instruction.getImplementedInterface());
 
         assertArrayEquals(
-            ByteUtil
-                .convertBigIntegerToNBytes(metadata, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
-            ByteUtil
-                .convertBigIntegerToNBytes(WriteMetadataCase.class.cast(instruction).getWriteMetadata().getMetadata(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
+                ByteUtil
+                        .convertBigIntegerToNBytes(metadata, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
+                ByteUtil
+                        .convertBigIntegerToNBytes(WriteMetadataCase.class.cast(instruction).getWriteMetadata()
+                                .getMetadata(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
 
         assertArrayEquals(
-            ByteUtil
-                .convertBigIntegerToNBytes(metadataMask, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
-            ByteUtil
-                .convertBigIntegerToNBytes(WriteMetadataCase.class.cast(instruction).getWriteMetadata().getMetadataMask(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
+                ByteUtil
+                        .convertBigIntegerToNBytes(metadataMask, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
+                ByteUtil
+                        .convertBigIntegerToNBytes(WriteMetadataCase.class.cast(instruction).getWriteMetadata()
+                                .getMetadataMask(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
 
         assertEquals(0, in.readableBytes());
     }
index 893da22b934e813f0a764569efacbac44cba71d0..565758276877815614a0ad46a45a2be1bfb6ef36 100644 (file)
@@ -87,7 +87,9 @@ public abstract class AbstractMatchEntryDeserializerTest extends AbstractDeseria
     }
 
     protected abstract int getOxmClassCode();
+
     protected abstract int getOxmFieldCode();
+
     protected abstract int getValueLength();
 
 }
index fa8f87d2a13f2ce29f016d122f2ae5cc8f35d1e5..c3f29db1d70bc68790f946374f29856a03b04cf1 100644 (file)
@@ -32,7 +32,8 @@ public class ArpSourceHardwareAddressEntryDeserializerTest extends AbstractMatch
         in.writeBytes(IetfYangUtil.INSTANCE.bytesFor(arpSourceHardwareAddress));
 
         assertEquals(arpSourceHardwareAddress.getValue(),
-                ArpMatch.class.cast(deserialize(in).getLayer3Match()).getArpSourceHardwareAddress().getAddress().getValue());
+                ArpMatch.class.cast(deserialize(in).getLayer3Match()).getArpSourceHardwareAddress().getAddress()
+                        .getValue());
         assertEquals(0, in.readableBytes());
 
         writeHeader(in, true);
index 36ec142209ed2d760e2864fd4aa5b5e88243180e..1188ade3b26990a30e666aed13ffc778515f6ef6 100644 (file)
@@ -32,7 +32,8 @@ public class ArpTargetHardwareAddressEntryDeserializerTest extends AbstractMatch
         in.writeBytes(IetfYangUtil.INSTANCE.bytesFor(arpTargetHardwareAddress));
 
         assertEquals(arpTargetHardwareAddress.getValue(),
-                ArpMatch.class.cast(deserialize(in).getLayer3Match()).getArpTargetHardwareAddress().getAddress().getValue());
+                ArpMatch.class.cast(deserialize(in).getLayer3Match()).getArpTargetHardwareAddress().getAddress()
+                        .getValue());
         assertEquals(0, in.readableBytes());
 
         writeHeader(in, true);
index 41da2f7cedcfa4633705174903312b48c6e40b9e..1c488ec2985a17e057e520837eed95dcfa7d91cd 100644 (file)
@@ -30,7 +30,8 @@ public class EthernetDestinationEntryDeserializerTest extends AbstractMatchEntry
         writeHeader(in, false);
         in.writeBytes(IetfYangUtil.INSTANCE.bytesFor(ethernetDestinationAddress));
 
-        assertEquals(ethernetDestinationAddress.getValue(), deserialize(in).getEthernetMatch().getEthernetDestination().getAddress().getValue());
+        assertEquals(ethernetDestinationAddress.getValue(), deserialize(in).getEthernetMatch().getEthernetDestination()
+                .getAddress().getValue());
         assertEquals(0, in.readableBytes());
 
         writeHeader(in, true);
index 30c2534e6a3351bcedf043cfe2595120d5416c0d..ed83b661ac163e3e1021214d36aabe1ba152efe9 100644 (file)
@@ -30,7 +30,8 @@ public class EthernetSourceEntryDeserializerTest extends AbstractMatchEntryDeser
         writeHeader(in, false);
         in.writeBytes(IetfYangUtil.INSTANCE.bytesFor(ethernetSourceAddress));
 
-        assertEquals(ethernetSourceAddress.getValue(), deserialize(in).getEthernetMatch().getEthernetSource().getAddress().getValue());
+        assertEquals(ethernetSourceAddress.getValue(),
+                deserialize(in).getEthernetMatch().getEthernetSource().getAddress().getValue());
         assertEquals(0, in.readableBytes());
 
         writeHeader(in, true);
index 907a05a27f3bfa4350412504adcff441844a4bf4..5360d05ef2c45f5c5ed1cd6ec54ede1b82702b5e 100644 (file)
@@ -10,10 +10,9 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
-import java.util.Iterator;
-
 import io.netty.buffer.ByteBuf;
 import io.netty.buffer.UnpooledByteBufAllocator;
+import java.util.Iterator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
index aa7cfb85987cec0900b2c68f03841bb15cda519c..3f52d80e861af2687c4671b9a3cf426a1ad93b1d 100644 (file)
@@ -10,10 +10,9 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
-import java.util.Iterator;
-
 import io.netty.buffer.ByteBuf;
 import io.netty.buffer.UnpooledByteBufAllocator;
+import java.util.Iterator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
index 8c65891ba0495ac9be38d09198b64460a80f6e7d..cbd6d6225c3f2c1962ea1259b01e6a204688eb15 100644 (file)
@@ -8,9 +8,11 @@
 
 package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
-import static org.junit.Assert.assertEquals;
 import static org.junit.Assert.assertArrayEquals;
+import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
@@ -18,9 +20,6 @@ import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.
 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.layer._3.match.Ipv6Match;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class Ipv6NdTargetEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
index 23eba5bd045ee1823776bcb723db9c920e914310..e9853d9e877aa6073dcd1f15d3ef18c1290c24d3 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.ProtocolMatchFields;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class MplsBosEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
index 25767acf979673aee007edbe3bb920690a5968cd..e6d96d2d152da5c07456b1d306526ff698658824 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.ProtocolMatchFields;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class MplsLabelEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
index 4ce947718f6b48936b277a2d9f4e2c296b328252..bdba3a8b14012dfccb733a28c81acd0ed934d305 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.ProtocolMatchFields;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class MplsTcEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
index d149c97f81a558acb35a04a79e2f151fb6e2183a..57d5b52ee1dc1d097090187e355ff4a7c737b1d6 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.ProtocolMatchFields;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class PbbEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
index e2df9f5dc21a2af050f54a9db32e318a83c97b0f..f470ad731484f010c31d322f547c865064b1efb4 100644 (file)
@@ -27,7 +27,8 @@ public class SctpDestinationPortEntryDeserializerTest extends AbstractMatchEntry
         writeHeader(in, false);
         in.writeShort(port);
 
-        assertEquals(port, SctpMatch.class.cast(deserialize(in).getLayer4Match()).getSctpDestinationPort().getValue().intValue());
+        assertEquals(port, SctpMatch.class.cast(deserialize(in).getLayer4Match()).getSctpDestinationPort().getValue()
+                .intValue());
         assertEquals(0, in.readableBytes());
     }
 
index b4681511e9721691992d35b97beefba48dd4aaca..713389552537959ec758c302e78499427907593f 100644 (file)
@@ -27,7 +27,8 @@ public class SctpSourcePortEntryDeserializerTest extends AbstractMatchEntryDeser
         writeHeader(in, false);
         in.writeShort(port);
 
-        assertEquals(port, SctpMatch.class.cast(deserialize(in).getLayer4Match()).getSctpSourcePort().getValue().intValue());
+        assertEquals(port, SctpMatch.class.cast(deserialize(in).getLayer4Match()).getSctpSourcePort().getValue()
+                .intValue());
         assertEquals(0, in.readableBytes());
     }
 
index 97521b9227a60fb7199bdeecd3724ad96fb946a2..35d64f8046d47ba82b2db4c0fb1eb12c7ae9395a 100644 (file)
@@ -27,7 +27,8 @@ public class TcpDestinationPortEntryDeserializerTest extends AbstractMatchEntryD
         writeHeader(in, false);
         in.writeShort(port);
 
-        assertEquals(port, TcpMatch.class.cast(deserialize(in).getLayer4Match()).getTcpDestinationPort().getValue().intValue());
+        assertEquals(port, TcpMatch.class.cast(deserialize(in).getLayer4Match()).getTcpDestinationPort().getValue()
+                .intValue());
         assertEquals(0, in.readableBytes());
     }
 
index 020f30525a5b07d20b779705d578fdfd391d5a4f..5aef1bd0f001768487f3d41a1651c6963b4b4b3d 100644 (file)
@@ -10,14 +10,13 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.TcpFlagsMatch;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class TcpFlagsEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
index fbb4bf16cde4cb87735efff43e6a77a7411e3961..f0b1725dfacd8bd50e759852f3ca8c1e7ab42c50 100644 (file)
@@ -27,7 +27,8 @@ public class TcpSourcePortEntryDeserializerTest extends AbstractMatchEntryDeseri
         writeHeader(in, false);
         in.writeShort(port);
 
-        assertEquals(port, TcpMatch.class.cast(deserialize(in).getLayer4Match()).getTcpSourcePort().getValue().intValue());
+        assertEquals(port, TcpMatch.class.cast(deserialize(in).getLayer4Match()).getTcpSourcePort().getValue()
+                .intValue());
         assertEquals(0, in.readableBytes());
     }
 
index b3432b2995c52374a0a039d993c9ffa8964ca446..4b3f0e7a40aad30cc9f8ef8692954dbae031aa68 100644 (file)
@@ -11,6 +11,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.match;
 import static org.junit.Assert.assertArrayEquals;
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import java.math.BigInteger;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
@@ -18,9 +20,6 @@ import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
 import org.opendaylight.openflowplugin.openflow.md.util.ByteUtil;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026.match.Tunnel;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class TunnelIdEntryDeserializerTest extends AbstractMatchEntryDeserializerTest {
 
     @Test
@@ -34,8 +33,8 @@ public class TunnelIdEntryDeserializerTest extends AbstractMatchEntryDeserialize
 
         Tunnel match = deserialize(in).getTunnel();
         assertArrayEquals(
-            ByteUtil.convertBigIntegerToNBytes(tunnelId, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
-            ByteUtil.convertBigIntegerToNBytes(match.getTunnelId(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
+                ByteUtil.convertBigIntegerToNBytes(tunnelId, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
+                ByteUtil.convertBigIntegerToNBytes(match.getTunnelId(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
 
         assertEquals(0, in.readableBytes());
 
@@ -45,11 +44,11 @@ public class TunnelIdEntryDeserializerTest extends AbstractMatchEntryDeserialize
 
         match = deserialize(in).getTunnel();
         assertArrayEquals(
-            ByteUtil.convertBigIntegerToNBytes(tunnelId, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
-            ByteUtil.convertBigIntegerToNBytes(match.getTunnelId(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
+                ByteUtil.convertBigIntegerToNBytes(tunnelId, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
+                ByteUtil.convertBigIntegerToNBytes(match.getTunnelId(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
         assertArrayEquals(
-            ByteUtil.convertBigIntegerToNBytes(tunnelIdMask, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
-            ByteUtil.convertBigIntegerToNBytes(match.getTunnelMask(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
+                ByteUtil.convertBigIntegerToNBytes(tunnelIdMask, EncodeConstants.SIZE_OF_LONG_IN_BYTES),
+                ByteUtil.convertBigIntegerToNBytes(match.getTunnelMask(), EncodeConstants.SIZE_OF_LONG_IN_BYTES));
         assertEquals(0, in.readableBytes());
     }
 
index 5120b6499f40ed11c0309b24a3764c530b9a3ee7..5eb9c14ff28625d2a3484c865a71ab899753b5cb 100644 (file)
@@ -27,7 +27,8 @@ public class UdpDestinationPortEntryDeserializerTest extends AbstractMatchEntryD
         writeHeader(in, false);
         in.writeShort(port);
 
-        assertEquals(port, UdpMatch.class.cast(deserialize(in).getLayer4Match()).getUdpDestinationPort().getValue().intValue());
+        assertEquals(port, UdpMatch.class.cast(deserialize(in).getLayer4Match()).getUdpDestinationPort().getValue()
+                .intValue());
         assertEquals(0, in.readableBytes());
     }
 
index c323e9204187677cf5f0e270c6414ab996d030f8..1145b9a1d45a0a0586e173a2ae8eff91ee8b7193 100644 (file)
@@ -27,7 +27,8 @@ public class UdpSourcePortEntryDeserializerTest extends AbstractMatchEntryDeseri
         writeHeader(in, false);
         in.writeShort(port);
 
-        assertEquals(port, UdpMatch.class.cast(deserialize(in).getLayer4Match()).getUdpSourcePort().getValue().intValue());
+        assertEquals(port, UdpMatch.class.cast(deserialize(in).getLayer4Match()).getUdpSourcePort().getValue()
+                .intValue());
         assertEquals(0, in.readableBytes());
     }
 
index ba1d95e7baffa8a781b5f59f7119da4a205720f0..fd1d975204b0f636b5c3663c8f738c6c5bab11d7 100644 (file)
@@ -25,7 +25,7 @@ public class VlanVidEntryDeserializerTest extends AbstractMatchEntryDeserializer
     public void deserializeEntry() throws Exception {
         final ByteBuf in = UnpooledByteBufAllocator.DEFAULT.buffer();
         final int vlanVid = 8;
-        final byte[] vlanMask = new byte[] { 16, 0 };
+        final byte[] vlanMask = new byte[]{16, 0};
 
         writeHeader(in, false);
         in.writeShort(vlanVid | (1 << 12));
index b25cd90ecf31c6fc8234229696407d640d0cbd8e..89837a405e0d70d6e0cfd003ca700e8c48eb8de2 100644 (file)
@@ -10,6 +10,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.messages;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.api.util.OxmMatchConstants;
@@ -24,9 +26,6 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instru
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.ApplyActionsCase;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.FlowModCommand;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class FlowMessageDeserializerTest extends AbstractDeserializerTest {
 
     private static final byte PADDING = 2;
index fe15c4638c81ff0d1bd25c60c1f9a73f13f77496..3a24e8e1307e1b24be51d0e97e532b4927f414dc 100644 (file)
@@ -10,6 +10,8 @@ package org.opendaylight.openflowplugin.impl.protocol.deserialization.messages;
 
 import static org.junit.Assert.assertEquals;
 
+import io.netty.buffer.ByteBuf;
+import io.netty.buffer.UnpooledByteBufAllocator;
 import org.junit.Test;
 import org.opendaylight.openflowjava.protocol.api.util.EncodeConstants;
 import org.opendaylight.openflowjava.protocol.impl.util.ActionConstants;
@@ -20,9 +22,6 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.Group
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.group.buckets.Bucket;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.GroupModCommand;
 
-import io.netty.buffer.ByteBuf;
-import io.netty.buffer.UnpooledByteBufAllocator;
-
 public class GroupMessageDeserializerTest extends AbstractDeserializerTest {
 
     private static final byte PADDING = 1;
index 1e2275c1c27f9f0dcc28784faadfab342c8e53f4..a41db26db3adb5c9d0f4bdbf7204d86ee2af25c0 100644 (file)
@@ -72,7 +72,8 @@ public class PacketInMessageDeserializerTest extends AbstractDeserializerTest {
         buffer.writeZero(PADDING_IN_PACKET_IN_HEADER);
         buffer.writeBytes(PAYLOAD);
 
-        final PacketInMessage message = (PacketInMessage) getFactory().deserialize(buffer, EncodeConstants.OF13_VERSION_ID);
+        final PacketInMessage message =
+                (PacketInMessage) getFactory().deserialize(buffer, EncodeConstants.OF13_VERSION_ID);
 
         assertEquals(XID, message.getXid().intValue());
         assertEquals(PacketInUtil.getMdSalPacketInReason(org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common
index fce52a43c6a5a4489d7f7f28804ee77d014ee8ba..e1a36578d71a508d22f458d5ac162ee7e0b082b0 100644 (file)
@@ -17,8 +17,8 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.statistics.rev130819.m
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.MultipartType;
 
 public class MultipartReplyFlowAggregateStatsDeserializerTest extends AbstractMultipartDeserializerTest {
-    private static final long PACKET_COUNT = 6l;
-    private static final long BYTE_COUNT = 256l;
+    private static final long PACKET_COUNT = 6L;
+    private static final long BYTE_COUNT = 256L;
     private static final int FLOW_COUNT = 3;
     private static final byte PADDING_IN_MULTIPART_REPLY_HEADER = 4;
 
index 963a54ebd0685fafb456d2d882a61bc717ab73d6..8d40c5a2488cbeab84a6d2eed1c16cd62f564e99 100644 (file)
@@ -29,7 +29,7 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instru
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.rev131026.instruction.instruction.WriteActionsCase;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.MultipartType;
 
-public class MultipartReplyFlowStatsDeserializerTest extends AbstractMultipartDeserializerTest{
+public class MultipartReplyFlowStatsDeserializerTest extends AbstractMultipartDeserializerTest {
 
     private static final byte PADDING_IN_FLOW_STATS_HEADER_01 = 1;
     private static final byte PADDING_IN_FLOW_STATS_HEADER_02 = 4;
@@ -144,7 +144,8 @@ public class MultipartReplyFlowStatsDeserializerTest extends AbstractMultipartDe
 
         assertEquals(2, flowAndStatisticsMapList.getInstructions().getInstruction().size());
 
-        final Instruction instruction = flowAndStatisticsMapList.getInstructions().getInstruction().get(0).getInstruction();
+        final Instruction instruction =
+                flowAndStatisticsMapList.getInstructions().getInstruction().get(0).getInstruction();
         assertEquals(ApplyActionsCase.class, instruction.getImplementedInterface());
 
         final ApplyActionsCase applyActions = ApplyActionsCase.class.cast(instruction);
@@ -152,7 +153,8 @@ public class MultipartReplyFlowStatsDeserializerTest extends AbstractMultipartDe
         assertEquals(PopPbbActionCase.class, applyActions.getApplyActions().getAction().get(0)
                 .getAction().getImplementedInterface());
 
-        final Instruction instruction1 = flowAndStatisticsMapList.getInstructions().getInstruction().get(1).getInstruction();
+        final Instruction instruction1 =
+                flowAndStatisticsMapList.getInstructions().getInstruction().get(1).getInstruction();
         assertEquals(WriteActionsCase.class, instruction1.getImplementedInterface());
 
         final WriteActionsCase writeActions = WriteActionsCase.class.cast(instruction1);
index 83dde69f3326235ecbd152b11e78b85f9a348e69..8613feb8697e4e3714bfe20ca5db6e8a4a198db0 100644 (file)
@@ -18,8 +18,8 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev13
 
 public class MultipartReplyFlowTableStatsDeserializerTest extends AbstractMultipartDeserializerTest {
     private static final byte TABLE_ID = 2;
-    private static final long PACKETS_LOOKEDUP = 1l;
-    private static final long PACKETS_MATCHED = 2l;
+    private static final long PACKETS_LOOKEDUP = 1L;
+    private static final long PACKETS_MATCHED = 2L;
     private static final int ACTIVE_FLOWS = 3;
     private static final byte PADDING_IN_TABLE_HEADER = 3;
 
@@ -35,8 +35,10 @@ public class MultipartReplyFlowTableStatsDeserializerTest extends AbstractMultip
         final MultipartReplyFlowTableStats reply = (MultipartReplyFlowTableStats) deserializeMultipart(buffer);
         assertEquals(TABLE_ID, reply.getFlowTableAndStatisticsMap().get(0).getTableId().getValue().byteValue());
         assertEquals(ACTIVE_FLOWS, reply.getFlowTableAndStatisticsMap().get(0).getActiveFlows().getValue().intValue());
-        assertEquals(PACKETS_LOOKEDUP, reply.getFlowTableAndStatisticsMap().get(0).getPacketsLookedUp().getValue().longValue());
-        assertEquals(PACKETS_MATCHED, reply.getFlowTableAndStatisticsMap().get(0).getPacketsMatched().getValue().longValue());
+        assertEquals(PACKETS_LOOKEDUP, reply.getFlowTableAndStatisticsMap().get(0).getPacketsLookedUp().getValue()
+                .longValue());
+        assertEquals(PACKETS_MATCHED, reply.getFlowTableAndStatisticsMap().get(0).getPacketsMatched().getValue()
+                .longValue());
         assertEquals(0, buffer.readableBytes());
     }
 
index f3b86dd1c4feff3f32087fb569b99f148729cf98..a139ee2d4023ae4a079c3017bdd3be7fd8992dfa 100644 (file)
@@ -18,7 +18,7 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.group.statistics.rev131111.
 import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.GroupTypes;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.MultipartType;
 
-public class MultipartReplyGroupDescDeserializerTest extends AbstractMultipartDeserializerTest{
+public class MultipartReplyGroupDescDeserializerTest extends AbstractMultipartDeserializerTest {
     private static final byte PADDING_IN_GROUP_DESC_HEADER = 1;
     private static final byte PADDING_IN_BUCKETS_HEADER = 4;
     private static final short ITEM_LENGTH = 32;
@@ -51,8 +51,10 @@ public class MultipartReplyGroupDescDeserializerTest extends AbstractMultipartDe
 
         assertEquals(GROUP_ID, reply.getGroupDescStats().get(0).getGroupId().getValue().intValue());
         assertEquals(WEIGHT, reply.getGroupDescStats().get(0).getBuckets().getBucket().get(0).getWeight().intValue());
-        assertEquals(WATCH_PORT, reply.getGroupDescStats().get(0).getBuckets().getBucket().get(0).getWatchPort().intValue());
-        assertEquals(WATCH_GROUP, reply.getGroupDescStats().get(0).getBuckets().getBucket().get(0).getWatchGroup().intValue());
+        assertEquals(WATCH_PORT, reply.getGroupDescStats().get(0).getBuckets().getBucket().get(0).getWatchPort()
+                .intValue());
+        assertEquals(WATCH_GROUP, reply.getGroupDescStats().get(0).getBuckets().getBucket().get(0).getWatchGroup()
+                .intValue());
         assertEquals(GROUP_TYPE, reply.getGroupDescStats().get(0).getGroupType().getIntValue());
         assertEquals(0, buffer.readableBytes());
     }
index e7fbb80e5c38dc2523803a456c9785df6119b54a..1de6d0ca60c7f91663692cbc1a5b820dfd143cbd 100644 (file)
@@ -28,8 +28,8 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.group.types.rev131018.Group
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.MultipartType;
 
 public class MultipartReplyGroupFeaturesDeserializerTest extends AbstractMultipartDeserializerTest {
-    private static final List<Long> MAX_GROUPS_LIST = Arrays.asList(1l, 2l, 3l, 4l);
-    private static final List<Long> ACTIONS_LIST = Arrays.asList(5l, 6l, 7l, 8l);
+    private static final List<Long> MAX_GROUPS_LIST = Arrays.asList(1L, 2L, 3L, 4L);
+    private static final List<Long> ACTIONS_LIST = Arrays.asList(5L, 6L, 7L, 8L);
 
     private static final List<GroupTypes> GROUP_TYPES_SUPPORTED = Arrays.asList(
             GroupTypes.GroupAll,
index 367abcc0267c3930cb9a0a512f03717a325d2d57..bf7070873bb1876cec265ead453299dced2f59ff 100644 (file)
@@ -25,8 +25,8 @@ public class MultipartReplyGroupStatsDeserializerTest extends AbstractMultipartD
     private static final int REF_COUNT = 4;
     private static final int SECOND = 5;
     private static final int NANOSECOND = 6;
-    private static final long PACKET_COUNT = 1l;
-    private static final long BYTE_COUNT = 2l;
+    private static final long PACKET_COUNT = 1L;
+    private static final long BYTE_COUNT = 2L;
 
     @Test
     public void testDeserialize() throws Exception {
index 8a401ffda4a04b746d2d8e3ea01b07b8ed0097ce..ff882a3405ee5d000636e3c0deff379f8f9c5a7a 100644 (file)
@@ -148,7 +148,8 @@ public class MultipartReplyMessageDeserializerTest extends AbstractDeserializerT
 
         assertEquals(1, flowAndStatisticsMapList.getInstructions().getInstruction().size());
 
-        final Instruction instruction = flowAndStatisticsMapList.getInstructions().getInstruction().get(0).getInstruction();
+        final Instruction instruction =
+                flowAndStatisticsMapList.getInstructions().getInstruction().get(0).getInstruction();
         assertEquals(ApplyActionsCase.class, instruction.getImplementedInterface());
 
         final ApplyActionsCase applyActions = ApplyActionsCase.class.cast(instruction);
index 5a97ca3f9a995280ccb7264910b14dda980c3ae0..e790b3953240542c25a9fadd66f2bc534b4f69ff 100644 (file)
@@ -26,7 +26,7 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.Meter
 import org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918.MeterStats;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.MultipartType;
 
-public class MultipartReplyMeterFeaturesDeserializerTest extends AbstractMultipartDeserializerTest{
+public class MultipartReplyMeterFeaturesDeserializerTest extends AbstractMultipartDeserializerTest {
     private static final int MAX_METER = 3;
     private static final List BANDS_SUPPORTED = Arrays.asList(MeterBandDrop.class);
     private static final List CAPABILITIES_SUPPORTED = Arrays.asList(MeterKbps.class, MeterBurst.class);
index c3e0f386aa19ed2e2ae17181d979af8411b11db7..1dc3e467b08d2b897b0dd5c5ae597f3f6af6ff26 100644 (file)
@@ -22,12 +22,12 @@ public class MultipartReplyMeterStatsDeserializerTest extends AbstractMultipartD
     private static final int METER_ID = 1;
     private static final short ITEM_LENGTH = 50;
     private static final int FLOW_COUNT = 2;
-    private static final long PACKET_IN_COUNT = 3l;
-    private static final long BYTE_IN_COUNT = 4l;
+    private static final long PACKET_IN_COUNT = 3L;
+    private static final long BYTE_IN_COUNT = 4L;
     private static final int SECOND = 5;
     private static final int NANOSECOND = 6;
-    private static final long PACKET_BAND_COUNT = 7l;
-    private static final long BYTE_BAND_COUNT = 8l;
+    private static final long PACKET_BAND_COUNT = 7L;
+    private static final long BYTE_BAND_COUNT = 8L;
 
     @Test
     public void deserialize() throws Exception {
index d01be07c96a2abdfb61744fc055c16de78fc1981..47ea9c1f51392b115fd5587fc02fdf248d46b4ff 100644 (file)
@@ -22,7 +22,7 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.port.rev130925.P
 import org.opendaylight.yang.gen.v1.urn.opendaylight.flow.types.port.rev130925.multipart.reply.multipart.reply.body.MultipartReplyPortDesc;
 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.types.rev130731.MultipartType;
 
-public class MultipartReplyPortDescDeserializerTest extends AbstractMultipartDeserializerTest{
+public class MultipartReplyPortDescDeserializerTest extends AbstractMultipartDeserializerTest {
     private static final byte PADDING_IN_PORT_DESC_HEADER_01 = 4;
     private static final byte PADDING_IN_PORT_DESC_HEADER_02 = 2;
 
index 6733b94d2a5a7942f7f208de3207873ad67853f3..9b5aec36606590c813a9f7afe550d93a7ada3560 100644 (file)
@@ -20,18 +20,18 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.port.statistics.rev131214.n
 public class MultipartReplyPortStatsDeserializerTest extends AbstractMultipartDeserializerTest {
     private static final byte PADDING_IN_PORT_STATS_HEADER = 4;
     private static final int PORT = 1;
-    private static final long PACKETS_RECEIVED = 2l;
-    private static final long PACKETS_TRANSMITTED = 3l;
-    private static final long BYTES_RECEIVED = 4l;
-    private static final long BYTES_TRANSMITTED = 5l;
-    private static final long RECEIVE_DROPS = 6l;
-    private static final long TRANSMIT_DROPS = 7l;
-    private static final long RECEIVE_ERRORS = 8l;
-    private static final long TRANSMIT_ERRORS = 9l;
-    private static final long RECEIVE_FRAME_ERROR = 10l;
-    private static final long RECEIVE_OVER_RUN_ERROR = 11l;
-    private static final long RECEIVE_CRC_ERROR = 12l;
-    private static final long COLLIESION_COUNT = 13l;
+    private static final long PACKETS_RECEIVED = 2L;
+    private static final long PACKETS_TRANSMITTED = 3L;
+    private static final long BYTES_RECEIVED = 4L;
+    private static final long BYTES_TRANSMITTED = 5L;
+    private static final long RECEIVE_DROPS = 6L;
+    private static final long TRANSMIT_DROPS = 7L;
+    private static final long RECEIVE_ERRORS = 8L;
+    private static final long TRANSMIT_ERRORS = 9L;
+    private static final long RECEIVE_FRAME_ERROR = 10L;
+    private static final long RECEIVE_OVER_RUN_ERROR = 11L;
+    private static final long RECEIVE_CRC_ERROR = 12L;
+    private static final long COLLIESION_COUNT = 13L;
     private static final int SECOND = 14;
     private static final int NANOSECOND = 15;
 
@@ -57,7 +57,8 @@ public class MultipartReplyPortStatsDeserializerTest extends AbstractMultipartDe
 
         final MultipartReplyPortStats reply = (MultipartReplyPortStats) deserializeMultipart(buffer);
 
-        final NodeConnectorStatisticsAndPortNumberMap portStats = reply.getNodeConnectorStatisticsAndPortNumberMap().get(0);
+        final NodeConnectorStatisticsAndPortNumberMap portStats =
+                reply.getNodeConnectorStatisticsAndPortNumberMap().get(0);
         assertEquals(PACKETS_RECEIVED, portStats.getPackets().getReceived().longValue());
         assertEquals(PACKETS_TRANSMITTED, portStats.getPackets().getTransmitted().longValue());
         assertEquals(BYTES_RECEIVED, portStats.getBytes().getReceived().longValue());
index fbedf4cb7cc803e6b38dca670b59d15a461425c7..98efa83cfb6bbc8a64f142442f0a6f2a5ab436c8 100644 (file)
@@ -20,9 +20,9 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.queue.statistics.rev131216.
 public class MultipartReplyQueueStatsDeserializerTest extends AbstractMultipartDeserializerTest {
     private static final int PORT = 1;
     private static final int QUEUE_ID = 1;
-    private static final long TRANSMITTED_BYTES = 5l;
-    private static final long TRANSMITTED_PACKETS = 3l;
-    private static final long TRANSMISSON_ERRORS = 9l;
+    private static final long TRANSMITTED_BYTES = 5L;
+    private static final long TRANSMITTED_PACKETS = 3L;
+    private static final long TRANSMISSON_ERRORS = 9L;
     private static final int SECOND = 14;
     private static final int NANOSECOND = 15;
 
index ab386259ec3565e1fda34cb99fb2e154f2e66077..943b517b1a46a1e4e02431a78cd433cc3ed71219 100644 (file)
@@ -42,8 +42,8 @@ public class MultipartReplyTableFeaturesDeserializerTest extends AbstractMultipa
     private static final byte TABLE_ID = 1;
     private static final long METADATA_MATCH = 2;
     private static final long METADATA_WRITE = 3;
-    private static final int  TABLE_CONFIG= 3;
-    private static final int  MAX_ENTRIES= 3;
+    private static final int  TABLE_CONFIG = 3;
+    private static final int  MAX_ENTRIES = 3;
 
     private static final int OFPTFPT_INSTRUCTIONS = 0;
     private static final int OFPTFPT_INSTRUCTIONS_MISS = 1;
@@ -156,10 +156,8 @@ public class MultipartReplyTableFeaturesDeserializerTest extends AbstractMultipa
     }
 
     private void writeValues(ByteBuf buffer, int propertyType) {
-        TableFeaturesPropType propType = TableFeaturesPropType.forValue(propertyType);
-
         buffer.clear();
-        int replyIndex = buffer.readerIndex();
+        final int replyIndex = buffer.readerIndex();
         buffer.writeShort(EncodeConstants.EMPTY_LENGTH);
         buffer.writeByte(TABLE_ID);
         buffer.writeZero(PADDING_IN_MULTIPART_REPLY_TABLE_FEATURES);
@@ -169,12 +167,14 @@ public class MultipartReplyTableFeaturesDeserializerTest extends AbstractMultipa
         buffer.writeInt(TABLE_CONFIG);
         buffer.writeInt(MAX_ENTRIES);
 
-        int propIndex = buffer.writerIndex();
+        final int propIndex = buffer.writerIndex();
         buffer.writeShort(propertyType);
 
-        int propLengthIndex = buffer.writerIndex();
+        final int propLengthIndex = buffer.writerIndex();
         buffer.writeShort(EncodeConstants.EMPTY_LENGTH);
 
+        TableFeaturesPropType propType = TableFeaturesPropType.forValue(propertyType);
+
         switch (propType) {
             case OFPTFPTINSTRUCTIONS:
             case OFPTFPTINSTRUCTIONSMISS:
index e39117f00b37d47afe6596fb892a9517d91d6dd4..b7e8412aeb45e1cd46aa0738102d79ebf8129cd5 100644 (file)
@@ -60,7 +60,7 @@ public abstract class AbstractSerializerTest {
 
         @Override
         public <K> void registerSerializer(MessageTypeKey<K> messageTypeKey, OFGeneralSerializer ofGeneralSerializer) {
-           registry.registerSerializer(messageTypeKey, ofGeneralSerializer);
+            registry.registerSerializer(messageTypeKey, ofGeneralSerializer);
         }
 
         @Override
@@ -70,43 +70,41 @@ public abstract class AbstractSerializerTest {
 
         @Override
         public void registerActionSerializer(ActionSerializerKey<?> key, OFGeneralSerializer serializer) {
-
         }
 
         @Override
         public void registerInstructionSerializer(InstructionSerializerKey<?> key, OFGeneralSerializer serializer) {
-
         }
 
         @Override
-        public <C extends OxmClassBase, F extends MatchField> void registerMatchEntrySerializer(MatchEntrySerializerKey<C, F> key, OFGeneralSerializer serializer) {
-
+        public <C extends OxmClassBase, F extends MatchField> void registerMatchEntrySerializer(
+                MatchEntrySerializerKey<C, F> key, OFGeneralSerializer serializer) {
         }
 
         @Override
-        public void registerExperimenterMessageSerializer(ExperimenterIdSerializerKey<? extends ExperimenterDataOfChoice> key, OFSerializer<? extends ExperimenterDataOfChoice> serializer) {
-
+        public void registerExperimenterMessageSerializer(ExperimenterIdSerializerKey<? extends
+                ExperimenterDataOfChoice> key, OFSerializer<? extends ExperimenterDataOfChoice> serializer) {
         }
 
         @Override
-        public void registerMultipartRequestSerializer(ExperimenterIdSerializerKey<? extends ExperimenterDataOfChoice> key, OFSerializer<? extends ExperimenterDataOfChoice> serializer) {
-
+        public void registerMultipartRequestSerializer(ExperimenterIdSerializerKey<? extends
+                ExperimenterDataOfChoice> key, OFSerializer<? extends ExperimenterDataOfChoice> serializer) {
         }
 
         @Override
-        public void registerMultipartRequestTFSerializer(ExperimenterIdSerializerKey<TableFeatureProperties> key, OFGeneralSerializer serializer) {
-
+        public void registerMultipartRequestTFSerializer(ExperimenterIdSerializerKey<TableFeatureProperties> key,
+                                                         OFGeneralSerializer serializer) {
         }
 
         @Override
-        public void registerMeterBandSerializer(ExperimenterIdSerializerKey<MeterBandExperimenterCase> key, OFSerializer<MeterBandExperimenterCase> serializer) {
+        public void registerMeterBandSerializer(ExperimenterIdSerializerKey<MeterBandExperimenterCase> key,
+                                                OFSerializer<MeterBandExperimenterCase> serializer) {
 
         }
 
         @Override
-        public void registerMeterBandSerializer(ExperimenterIdMeterSubTypeSerializerKey<MeterBandExperimenterCase> key, OFSerializer<MeterBandExperimenterCase> serializer) {
-
+        public void registerMeterBandSerializer(ExperimenterIdMeterSubTypeSerializerKey<MeterBandExperimenterCase>
+                                                            key, OFSerializer<MeterBandExperimenterCase> serializer) {
         }
     }
-
 }
\ No newline at end of file
index daa899539baf9fb6e09083d8d81e6e8b40f588ff..e1e24817cfb96a26fe0431c206ba6935d26eb369 100644 (file)
@@ -37,7 +37,8 @@ public class InstructionSerializerInjectorTest {
 
     @Before
     public void setUp() throws Exception {
-        injector = InstructionSerializerInjector.createInjector(switchConnectionProvider, EncodeConstants.OF13_VERSION_ID);
+        injector =
+                InstructionSerializerInjector.createInjector(switchConnectionProvider, EncodeConstants.OF13_VERSION_ID);
     }
 
     @Test
index 473e01a8c2e0dd84d16d20c39d4f6d34a0727a0c..879b91764d4f277d1c28ab6593772c4a0f88de43 100644 (file)
@@ -42,6 +42,7 @@ public class MessageSerializerInjectorTest {
     @Test
     public void injectSerializers() throws Exception {
         injector.apply(OfHeader.class).accept(ofSerializer);
-        verify(switchConnectionProvider).registerSerializer(new MessageTypeKey<>(OFConstants.OFP_VERSION_1_3, OfHeader.class), ofSerializer);
+        verify(switchConnectionProvider)
+                .registerSerializer(new MessageTypeKey<>(OFConstants.OFP_VERSION_1_3, OfHeader.class), ofSerializer);
     }
 }
\ No newline at end of file
index 7c6b6d3418417b4893d82fa1d43db6ae04b275cd..32dbea23fcbc2f0b6ac4a38e79c7ed70e3aa6d0f 100644 (file)
@@ -49,7 +49,9 @@ public abstract class AbstractActionSerializerTest extends AbstractSerializerTes
     }
 
     protected abstract Class<? extends Action> getClazz();
+
     protected abstract int getType();
+
     protected abstract int getLength();
 
 }
\ No newline at end of file
index 9e05b6865da54caec61b089380c1e5f9824653de..66f6ac63e4ba3167e4e1839db47062ccc7fd175a 100644 (file)
@@ -49,6 +49,8 @@ public abstract class AbstractInstructionSerializerTest extends AbstractSerializ
     }
 
     protected abstract Class<? extends Instruction> getClazz();
+
     protected abstract int getType();
+
     protected abstract int getLength();
 }
\ No newline at end of file
index 21efbee0a5bc19f63e5969305f32043143b38acf..71bcddef1c32ce3a3726c3d79726f3953ded3736 100644 (file)
@@ -18,7 +18,9 @@ import org.opendaylight.yang.gen.v1.urn.opendaylight.model.match.types.rev131026
 
 public abstract class AbstractExperimenterMatchEntrySerializerTest extends AbstractMatchEntrySerializerTest {
 
-    protected void assertMatch(final Match match, final boolean hasMask, final Consumer<ByteBuf> assertBody) throws Exception {
+    protected void assertMatch(final Match match,
+                               final boolean hasMask,
+                               final Consumer<ByteBuf> assertBody) throws Exception {
         final ByteBuf buffer = UnpooledByteBufAllocator.DEFAULT.buffer();
         getSerializer().serialize(match, buffer);
 
index 8815017613131c0b6b18061efa64cea44e6721db..69ba89747ea77499154a7e60f8737c57c807b687 100644 (file)
@@ -26,7 +26,9 @@ public abstract class AbstractMatchEntrySerializerTest extends AbstractSerialize
         serializer = getRegistry().getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, Match.class));
     }
 
-    protected void assertMatch(final Match match, final boolean hasMask, final Consumer<ByteBuf> assertBody) throws Exception {
+    protected void assertMatch(final Match match,
+                               final boolean hasMask,
+                               final Consumer<ByteBuf> assertBody) throws Exception {
         final ByteBuf buffer = UnpooledByteBufAllocator.DEFAULT.buffer();
         serializer.serialize(match, buffer);
 
@@ -63,7 +65,9 @@ public abstract class AbstractMatchEntrySerializerTest extends AbstractSerialize
     }
 
     protected abstract int getOxmFieldCode();
+
     protected abstract int getOxmClassCode();
+
     protected abstract short getLength();
 
 }
\ No newline at end of file
index fed3695008572812677ce481520070ba6e870a4f..719fc16e3087bf78d609e0285bc764942e7cbc82 100644 (file)
@@ -35,11 +35,13 @@ public class Ipv6DestinationEntrySerializerTest extends AbstractMatchEntrySerial
         assertMatch(ipv6abmMatch, true, (out) -> {
             byte[] address = new byte[16];
             out.readBytes(address);
-            assertArrayEquals(address, IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
+            assertArrayEquals(address,
+                    IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
 
             byte[] mask = new byte[16];
             out.readBytes(mask);
-            assertArrayEquals(mask, IpConversionUtil.convertIpv6PrefixToByteArray(IpConversionUtil.extractIpv6Prefix(ipv6Address)));
+            assertArrayEquals(mask,
+                    IpConversionUtil.convertIpv6PrefixToByteArray(IpConversionUtil.extractIpv6Prefix(ipv6Address)));
         });
     }
 
@@ -56,7 +58,8 @@ public class Ipv6DestinationEntrySerializerTest extends AbstractMatchEntrySerial
         assertMatch(ipv6abmMatch, false, (out) -> {
             byte[] address = new byte[16];
             out.readBytes(address);
-            assertArrayEquals(address, IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
+            assertArrayEquals(address,
+                    IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
         });
     }
 
index 96394d16e7475a159f7d0dbc0805e28e10206ad1..2fbc524c7bcdf6639d1562df1ba4ab40d1ad39ed 100644 (file)
@@ -34,7 +34,8 @@ public class Ipv6NdSllEntrySerializerTest extends AbstractMatchEntrySerializerTe
         assertMatch(ipv6NdSllMatch, false, (out) -> {
             byte[] addressBytes = new byte[6];
             out.readBytes(addressBytes);
-            assertEquals(new MacAddress(ByteBufUtils.macAddressToString(addressBytes)).getValue(), ipv6NdSll.getValue());
+            assertEquals(new MacAddress(ByteBufUtils.macAddressToString(addressBytes)).getValue(),
+                    ipv6NdSll.getValue());
         });
     }
 
index 4d50d6f9326605f7fc50d144789c545f7c3142ce..f9fbc4937bb23ebb82b5c0896634397865fac48c 100644 (file)
@@ -34,7 +34,8 @@ public class Ipv6NdTllEntrySerializerTest extends AbstractMatchEntrySerializerTe
         assertMatch(ipv6NdTllMatch, false, (out) -> {
             byte[] addressBytes = new byte[6];
             out.readBytes(addressBytes);
-            assertEquals(new MacAddress(ByteBufUtils.macAddressToString(addressBytes)).getValue(), ipv6NdTll.getValue());
+            assertEquals(new MacAddress(ByteBufUtils.macAddressToString(addressBytes)).getValue(),
+                    ipv6NdTll.getValue());
         });
     }
 
index 7bbfd77e6f5a9115a1d69c1d6433605dfae1dc79..bac5c263e1a3954bca999f5bbc988173ed30af9f 100644 (file)
@@ -35,11 +35,13 @@ public class Ipv6SourceEntrySerializerTest extends AbstractMatchEntrySerializerT
         assertMatch(ipv6abmMatch, true, (out) -> {
             byte[] address = new byte[16];
             out.readBytes(address);
-            assertArrayEquals(address, IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
+            assertArrayEquals(address,
+                    IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
 
             byte[] mask = new byte[16];
             out.readBytes(mask);
-            assertArrayEquals(mask, IpConversionUtil.convertIpv6PrefixToByteArray(IpConversionUtil.extractIpv6Prefix(ipv6Address)));
+            assertArrayEquals(mask,
+                    IpConversionUtil.convertIpv6PrefixToByteArray(IpConversionUtil.extractIpv6Prefix(ipv6Address)));
         });
     }
 
@@ -56,7 +58,8 @@ public class Ipv6SourceEntrySerializerTest extends AbstractMatchEntrySerializerT
         assertMatch(ipv6abmMatch, false, (out) -> {
             byte[] address = new byte[16];
             out.readBytes(address);
-            assertArrayEquals(address, IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
+            assertArrayEquals(address,
+                    IetfInetUtil.INSTANCE.ipv6AddressBytes(IpConversionUtil.extractIpv6Address(ipv6Address)));
         });
     }
 
index cfe0cf75e2a7137d8578508e8370114bd03639ac..26180c5f5f7bd30ae2b18dbcaf666086fdeaee3f 100644 (file)
@@ -48,7 +48,7 @@ public class VlanVidEntrySerializerTest extends AbstractMatchEntrySerializerTest
         assertMatch(vlanMatchMaskOnly, true, out -> {
             assertEquals(out.readShort(), (1 << 12));
 
-            byte mask[] = new byte[2];
+            byte[] mask = new byte[2];
             out.readBytes(mask);
             assertArrayEquals(mask, new byte[] { 16, 0 });
         });
index c4847f21fda18c31485838d1232f29a890874029..04fccd144786e56764c745f983be4d110979913c 100644 (file)
@@ -179,7 +179,8 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
     @Override
     protected void init() {
-        serializer = getRegistry().getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, FlowMessage.class));
+        serializer = getRegistry()
+                .getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, FlowMessage.class));
     }
 
     @Test
@@ -255,7 +256,7 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
         // Set vlan id action
         int setVlanIdLength = 16;
-        int setVlanStartIndex = out.readerIndex();
+        final int setVlanStartIndex = out.readerIndex();
         assertEquals(out.readUnsignedShort(), ActionConstants.SET_FIELD_CODE);
         assertEquals(out.readUnsignedShort(), setVlanIdLength);
         assertEquals(out.readUnsignedShort(), OxmMatchConstants.OPENFLOW_BASIC_CLASS);
@@ -276,7 +277,7 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
         // Set tp src action
         int setTpSrcLength = 16;
-        int setTpSrcStartIndex = out.readerIndex();
+        final int setTpSrcStartIndex = out.readerIndex();
         assertEquals(out.readUnsignedShort(), ActionConstants.SET_FIELD_CODE);
         assertEquals(out.readUnsignedShort(), setTpSrcLength);
         assertEquals(out.readUnsignedShort(), OxmMatchConstants.OPENFLOW_BASIC_CLASS);
@@ -297,7 +298,7 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
         // Set tp dst action
         int setTpDstLength = 16;
-        int setTpDstStartIndex = out.readerIndex();
+        final int setTpDstStartIndex = out.readerIndex();
         assertEquals(out.readUnsignedShort(), ActionConstants.SET_FIELD_CODE);
         assertEquals(out.readUnsignedShort(), setTpDstLength);
         assertEquals(out.readUnsignedShort(), OxmMatchConstants.OPENFLOW_BASIC_CLASS);
@@ -372,7 +373,7 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
         // Set vlan id action
         int setVlanIdLength = 16;
-        int setVlanStartIndex = out.readerIndex();
+        final int setVlanStartIndex = out.readerIndex();
         assertEquals(out.readUnsignedShort(), ActionConstants.SET_FIELD_CODE);
         assertEquals(out.readUnsignedShort(), setVlanIdLength);
         assertEquals(out.readUnsignedShort(), OxmMatchConstants.OPENFLOW_BASIC_CLASS);
@@ -393,7 +394,7 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
         // Set tp src action
         int setTpSrcLength = 16;
-        int setTpSrcStartIndex = out.readerIndex();
+        final int setTpSrcStartIndex = out.readerIndex();
         assertEquals(out.readUnsignedShort(), ActionConstants.SET_FIELD_CODE);
         assertEquals(out.readUnsignedShort(), setTpSrcLength);
         assertEquals(out.readUnsignedShort(), OxmMatchConstants.OPENFLOW_BASIC_CLASS);
@@ -414,7 +415,7 @@ public class FlowMessageSerializerTest extends AbstractSerializerTest {
 
         // Set tp dst action
         int setTpDstLength = 16;
-        int setTpDstStartIndex = out.readerIndex();
+        final int setTpDstStartIndex = out.readerIndex();
         assertEquals(out.readUnsignedShort(), ActionConstants.SET_FIELD_CODE);
         assertEquals(out.readUnsignedShort(), setTpDstLength);
         assertEquals(out.readUnsignedShort(), OxmMatchConstants.OPENFLOW_BASIC_CLASS);
index 368461a51563d55118f44da11450d7db4978ff88..f092579cdac1679b62571f0d5eb948de7a8ba56d 100644 (file)
@@ -101,7 +101,8 @@ public class GroupMessageSerializerTest extends AbstractSerializerTest {
 
     @Override
     protected void init() {
-        serializer = getRegistry().getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, GroupMessage.class));
+        serializer = getRegistry()
+                .getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, GroupMessage.class));
     }
 
     @Test
index 5bf30a587c98a735854bd0798836275db82690f0..16f417bad8a140fae8e69d1aaf6a80045767b031 100644 (file)
@@ -73,8 +73,8 @@ public class MeterMessageSerializerTest extends AbstractSerializerTest {
                     .setMeterBandHeader(Arrays.asList(
                             new MeterBandHeaderBuilder()
                                     .setMeterBandTypes(new MeterBandTypesBuilder()
-                                            .setFlags(new org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918
-                                                    .MeterBandType(true, false, false))
+                                            .setFlags(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                                                    .meter.types.rev130918.MeterBandType(true, false, false))
                                             .build())
                                     .setBandBurstSize(BAND_BURST_SIZE)
                                     .setBandId(new BandId(BAND_ID))
@@ -86,8 +86,8 @@ public class MeterMessageSerializerTest extends AbstractSerializerTest {
                                     .build(),
                             new MeterBandHeaderBuilder()
                                     .setMeterBandTypes(new MeterBandTypesBuilder()
-                                            .setFlags(new org.opendaylight.yang.gen.v1.urn.opendaylight.meter.types.rev130918
-                                                    .MeterBandType(false, true, false))
+                                            .setFlags(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                                                    .meter.types.rev130918.MeterBandType(false, true, false))
                                             .build())
                                     .setBandBurstSize(BAND_BURST_SIZE)
                                     .setBandId(new BandId(BAND_ID))
@@ -106,7 +106,8 @@ public class MeterMessageSerializerTest extends AbstractSerializerTest {
 
     @Override
     protected void init() {
-        serializer = getRegistry().getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, MeterMessage.class)) ;
+        serializer = getRegistry()
+                .getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, MeterMessage.class)) ;
     }
 
     @Test
index c3bcd5bdd26c323f01a7e4d9fac62250e4de2cf4..9cb7c2a80a2d1b62d4c98f6a7068e8e4d0b39d06 100644 (file)
@@ -94,7 +94,8 @@ public class PortMessageSerializerTest extends AbstractSerializerTest {
 
     @Override
     protected void init() {
-        serializer = getRegistry().getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, PortMessage.class));
+        serializer = getRegistry()
+                .getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, PortMessage.class));
     }
 
     @Test
index 43ee847696e6a096cb8f4c6c41a7aba878dbefc3..0338df7880ba4df9c35412d2d3a3cbe7b01c1188 100644 (file)
@@ -52,7 +52,8 @@ public class MultipartRequestMessageSerializerTest extends AbstractSerializerTes
 
     @Override
     protected void init() {
-        serializer = getRegistry().getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, MultipartRequest.class)) ;
+        serializer = getRegistry()
+                .getSerializer(new MessageTypeKey<>(EncodeConstants.OF13_VERSION_ID, MultipartRequest.class));
     }
 
     @Test
index 0452c2384cf06149e45228e23b9dc36f529a834f..bc1a9224244d95874110336c0de16981b53b36ec 100644 (file)
@@ -26,8 +26,8 @@ public class ApplyActionsMissTablePropertySerializerTest extends AbstractTablePr
     @Test
     public void testSerialize() throws Exception {
         final ApplyActionsMiss property = new ApplyActionsMissBuilder()
-                .setApplyActionsMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight.table.types.rev131026.table.feature
-                        .prop.type.table.feature.prop.type.apply.actions.miss
+                .setApplyActionsMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                        .table.types.rev131026.table.feature.prop.type.table.feature.prop.type.apply.actions.miss
                         .ApplyActionsMissBuilder()
                         .setAction(Collections.singletonList(new ActionBuilder()
                                 .setOrder(0)
index f05939303ccf65ec634dd3b75b55221ebd19e0f3..59562a6c8b9b87e166f83ab5c5c71c8700a1c21b 100644 (file)
@@ -27,8 +27,8 @@ public class ApplySetfieldMissTablePropertySerializerTest extends AbstractTableP
     @Test
     public void testSerialize() throws Exception {
         final ApplySetfieldMiss property = new ApplySetfieldMissBuilder()
-                .setApplySetfieldMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight.table.types.rev131026.table.feature
-                        .prop.type.table.feature.prop.type.apply.setfield.miss
+                .setApplySetfieldMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                        .table.types.rev131026.table.feature.prop.type.table.feature.prop.type.apply.setfield.miss
                         .ApplySetfieldMissBuilder()
                         .setSetFieldMatch(ImmutableList
                                 .<SetFieldMatch>builder()
index 50a5f102c9e64fea54ae62967e224ad9838d9018..85a30671a8fc9ae3805aa8384edb5759e6be3dda 100644 (file)
@@ -26,8 +26,8 @@ public class InstructionsMissTablePropertySerializerTest extends AbstractTablePr
     @Test
     public void testSerialize() throws Exception {
         final InstructionsMiss property = new InstructionsMissBuilder()
-                .setInstructionsMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight.table.types.rev131026.table.feature
-                        .prop.type.table.feature.prop.type.instructions.miss
+                .setInstructionsMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                        .table.types.rev131026.table.feature.prop.type.table.feature.prop.type.instructions.miss
                         .InstructionsMissBuilder()
                         .setInstruction(Collections.singletonList(new InstructionBuilder()
                                 .setOrder(0)
index d10a3482cd9f45c5467cc091dbecd146ee615d27..bd62929d693f2c0fdec5a94393322f0cb8246803 100644 (file)
@@ -26,8 +26,8 @@ public class WriteActionsMissTablePropertySerializerTest extends AbstractTablePr
     @Test
     public void testSerialize() throws Exception {
         final WriteActionsMiss property = new WriteActionsMissBuilder()
-                .setWriteActionsMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight.table.types.rev131026.table.feature
-                        .prop.type.table.feature.prop.type.write.actions.miss
+                .setWriteActionsMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                        .table.types.rev131026.table.feature.prop.type.table.feature.prop.type.write.actions.miss
                         .WriteActionsMissBuilder()
                         .setAction(Collections.singletonList(new ActionBuilder()
                                 .setOrder(0)
index 35608bee514fea304db4352748e3f9a53e6cbd3a..29373965dc693a9958f0316500186f4c2aac87f5 100644 (file)
@@ -27,8 +27,8 @@ public class WriteSetfieldMissTablePropertySerializerTest extends AbstractTableP
     @Test
     public void testSerialize() throws Exception {
         final WriteSetfieldMiss property = new WriteSetfieldMissBuilder()
-                .setWriteSetfieldMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight.table.types.rev131026.table.feature
-                        .prop.type.table.feature.prop.type.write.setfield.miss
+                .setWriteSetfieldMiss(new org.opendaylight.yang.gen.v1.urn.opendaylight
+                        .table.types.rev131026.table.feature.prop.type.table.feature.prop.type.write.setfield.miss
                         .WriteSetfieldMissBuilder()
                         .setSetFieldMatch(ImmutableList
                                 .<SetFieldMatch>builder()