X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;ds=sidebyside;f=openflow-protocol-api%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fopenflowjava%2Fprotocol%2Fapi%2Fkeys%2FActionSerializerKey.java;h=38b8cd498d075199a3b9f2d7ad294e757e317ed3;hb=0b1daa34f49ab93e08b5be06b50424c81efd0c82;hp=623bdea4b9bd238c99cf930b6ac07414f9405481;hpb=7c7f4343f27895a9d714f30bec878fe79b2aa809;p=openflowjava.git diff --git a/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/keys/ActionSerializerKey.java b/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/keys/ActionSerializerKey.java index 623bdea4..38b8cd49 100644 --- a/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/keys/ActionSerializerKey.java +++ b/openflow-protocol-api/src/main/java/org/opendaylight/openflowjava/protocol/api/keys/ActionSerializerKey.java @@ -33,16 +33,24 @@ public class ActionSerializerKey extends MessageTypeKey this.experimenterId = experimenterId; } + @Override + public int hashCode() { + final int prime = 31; + int result = super.hashCode(); + result = prime * result + ((actionType == null) ? 0 : actionType.hashCode()); + result = prime * result + ((experimenterId == null) ? 0 : experimenterId.hashCode()); + return result; + } + @Override public boolean equals(Object obj) { if (this == obj) return true; if (!super.equals(obj)) return false; - if (getClass() != obj.getClass()) + if (!(obj instanceof ActionSerializerKey)) return false; - @SuppressWarnings("rawtypes") - ActionSerializerKey other = (ActionSerializerKey) obj; + ActionSerializerKey other = (ActionSerializerKey) obj; if (actionType == null) { if (other.actionType != null) return false;