Make methods static
[openflowplugin.git] / extension / openflowjava-extension-nicira / src / test / java / org / opendaylight / openflowjava / nx / codec / match / Ipv6DstCodecTest.java
index 610d197ae35347b12895dcc4520d6fae2f5902c3..64c19d38133d88e24927e32d195a5433c4421c0d 100644 (file)
@@ -1,11 +1,10 @@
-/**
+/*
  * Copyright (c) 2017 Red Hat, Inc. and others.  All rights reserved.
  *
  * This program and the accompanying materials are made available under the
  * terms of the Eclipse Public License v1.0 which accompanies this distribution,
  * and is available at http://www.eclipse.org/legal/epl-v10.html
  */
-
 package org.opendaylight.openflowjava.nx.codec.match;
 
 import static org.junit.Assert.assertEquals;
@@ -57,7 +56,7 @@ public class Ipv6DstCodecTest {
 
         input = ipv6DstCodec.deserialize(buffer);
 
-        IpDstCaseValue result = ((IpDstCaseValue) input.getMatchEntryValue());
+        final IpDstCaseValue result = (IpDstCaseValue) input.getMatchEntryValue();
 
         assertEquals(Nxm1Class.class, input.getOxmClass());
         assertEquals(NxmOfIpDst.class, input.getOxmMatchField());
@@ -65,11 +64,10 @@ public class Ipv6DstCodecTest {
         assertEquals(2, result.getIpDstValues().getValue().intValue());
     }
 
-
-    private MatchEntry createMatchEntry() {
+    private static MatchEntry createMatchEntry() {
         MatchEntryBuilder matchEntryBuilder = new MatchEntryBuilder();
-        IpDstCaseValueBuilder caseBuilder = new IpDstCaseValueBuilder();
-        IpDstValuesBuilder valuesBuilder = new IpDstValuesBuilder();
+        final IpDstCaseValueBuilder caseBuilder = new IpDstCaseValueBuilder();
+        final IpDstValuesBuilder valuesBuilder = new IpDstValuesBuilder();
 
         matchEntryBuilder.setOxmClass(Nxm1Class.class);
         matchEntryBuilder.setOxmMatchField(NxmOfIpDst.class);
@@ -82,13 +80,12 @@ public class Ipv6DstCodecTest {
         return matchEntryBuilder.build();
     }
 
-    private void createBuffer(ByteBuf message) {
+    private static void createBuffer(ByteBuf message) {
         message.writeShort(OxmMatchConstants.NXM_1_CLASS);
 
-        int fieldMask = (NXM_FIELD_CODE << 1);
+        int fieldMask = NXM_FIELD_CODE << 1;
         message.writeByte(fieldMask);
         message.writeByte(VALUE_LENGTH);
         message.writeInt(2);
     }
-
 }