2 * Copyright (c) 2014 Pantheon Technologies s.r.o. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
9 package org.opendaylight.openflowjava.protocol.api.keys;
11 import org.opendaylight.yang.gen.v1.urn.opendaylight.openflow.common.action.rev150203.actions.grouping.Action;
14 * Key for an action deserializer.
16 * @author michal.polkorab
18 public class ActionDeserializerKey extends MessageCodeKey {
20 private final Long experimenterId;
25 * @param version protocol wire version
26 * @param type action type
27 * @param experimenterId experimenter / vendor ID
29 public ActionDeserializerKey(short version,
30 int type, Long experimenterId) {
31 super(version, type, Action.class);
32 this.experimenterId = experimenterId;
36 public int hashCode() {
38 int result = super.hashCode();
39 result = prime * result + (experimenterId == null ? 0 : experimenterId.hashCode());
44 public boolean equals(Object obj) {
48 if (!super.equals(obj)) {
51 if (!(obj instanceof ActionDeserializerKey)) {
54 ActionDeserializerKey other = (ActionDeserializerKey) obj;
55 if (experimenterId == null) {
56 if (other.experimenterId != null) {
59 } else if (!experimenterId.equals(other.experimenterId)) {
66 public String toString() {
67 return super.toString() + " experimenterID: " + experimenterId;