commit | 5bae20c840be3d59747c5a29cc558d6fdbd29afc | [log] [tgz] |
---|---|---|
author | Satish K <satishk@huawei.com> | Sat Nov 28 14:43:48 2015 +0530 |
committer | Gerrit Code Review <gerrit@onlab.us> | Sun Nov 29 23:35:21 2015 +0000 |
tree | bae6736cf6179407b3372c08685cf61ef55d8529 | |
parent | 05b882c8727a00421b4a62497cd9c27cd235afda [diff] |
Equals and Hash code fix for byte array Change-Id: I074070da647cb5eae0b9ec5b810ac1c813ebd87b
diff --git a/protocols/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/RouterIDSubTlv.java b/protocols/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/RouterIDSubTlv.java index 9b27ce1..228d853 100644 --- a/protocols/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/RouterIDSubTlv.java +++ b/protocols/pcep/pcepio/src/main/java/org/onosproject/pcepio/types/RouterIDSubTlv.java
@@ -15,7 +15,7 @@ */ package org.onosproject.pcepio.types; -import java.util.Objects; +import java.util.Arrays; import org.jboss.netty.buffer.ChannelBuffer; import org.onosproject.pcepio.protocol.PcepVersion; @@ -99,7 +99,7 @@ @Override public int hashCode() { - return Objects.hash(rawValue); + return Arrays.hashCode(rawValue); } @Override @@ -109,7 +109,7 @@ } if (obj instanceof RouterIDSubTlv) { RouterIDSubTlv other = (RouterIDSubTlv) obj; - return Objects.equals(this.rawValue, other.rawValue); + return Arrays.equals(this.rawValue, other.rawValue); } return false; }