Satish K
Committed by Gerrit Code Review

Equals and Hashcode issue fix

Change-Id: I2017d251d2acd418cc057b3e16df072985d30dce
...@@ -15,7 +15,7 @@ ...@@ -15,7 +15,7 @@
15 */ 15 */
16 package org.onosproject.bgpio.types; 16 package org.onosproject.bgpio.types;
17 17
18 -import java.util.Objects; 18 +import java.util.Arrays;
19 19
20 import org.jboss.netty.buffer.ChannelBuffer; 20 import org.jboss.netty.buffer.ChannelBuffer;
21 import org.onosproject.bgpio.protocol.IGPRouterID; 21 import org.onosproject.bgpio.protocol.IGPRouterID;
...@@ -65,7 +65,7 @@ public class IsIsNonPseudonode implements IGPRouterID, BGPValueType { ...@@ -65,7 +65,7 @@ public class IsIsNonPseudonode implements IGPRouterID, BGPValueType {
65 65
66 @Override 66 @Override
67 public int hashCode() { 67 public int hashCode() {
68 - return Objects.hash(isoNodeID); 68 + return Arrays.hashCode(isoNodeID);
69 } 69 }
70 70
71 @Override 71 @Override
...@@ -75,7 +75,7 @@ public class IsIsNonPseudonode implements IGPRouterID, BGPValueType { ...@@ -75,7 +75,7 @@ public class IsIsNonPseudonode implements IGPRouterID, BGPValueType {
75 } 75 }
76 if (obj instanceof IsIsNonPseudonode) { 76 if (obj instanceof IsIsNonPseudonode) {
77 IsIsNonPseudonode other = (IsIsNonPseudonode) obj; 77 IsIsNonPseudonode other = (IsIsNonPseudonode) obj;
78 - return Objects.equals(isoNodeID, other.isoNodeID); 78 + return Arrays.equals(isoNodeID, other.isoNodeID);
79 } 79 }
80 return false; 80 return false;
81 } 81 }
......
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
16 16
17 package org.onosproject.pcepio.types; 17 package org.onosproject.pcepio.types;
18 18
19 -import java.util.Objects; 19 +import java.util.Arrays;
20 20
21 import org.jboss.netty.buffer.ChannelBuffer; 21 import org.jboss.netty.buffer.ChannelBuffer;
22 import org.onosproject.pcepio.protocol.PcepVersion; 22 import org.onosproject.pcepio.protocol.PcepVersion;
...@@ -168,7 +168,7 @@ public class IPv6SubObject implements PcepValueType { ...@@ -168,7 +168,7 @@ public class IPv6SubObject implements PcepValueType {
168 168
169 @Override 169 @Override
170 public int hashCode() { 170 public int hashCode() {
171 - return Objects.hash(rawValue); 171 + return Arrays.hashCode(rawValue);
172 } 172 }
173 173
174 @Override 174 @Override
...@@ -178,7 +178,7 @@ public class IPv6SubObject implements PcepValueType { ...@@ -178,7 +178,7 @@ public class IPv6SubObject implements PcepValueType {
178 } 178 }
179 if (obj instanceof IPv6SubObject) { 179 if (obj instanceof IPv6SubObject) {
180 IPv6SubObject other = (IPv6SubObject) obj; 180 IPv6SubObject other = (IPv6SubObject) obj;
181 - return Objects.equals(rawValue, other.rawValue); 181 + return Arrays.equals(rawValue, other.rawValue);
182 } 182 }
183 return false; 183 return false;
184 } 184 }
......