2 * Copyright (c) 2014 Cisco Systems, Inc. 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.controller.cluster.datastore.messages;
12 public class PrimaryFound implements SerializableMessage {
13 public static final Class<PrimaryFound> SERIALIZABLE_CLASS = PrimaryFound.class;
14 private final String primaryPath;
16 public PrimaryFound(final String primaryPath) {
17 this.primaryPath = primaryPath;
20 public String getPrimaryPath() {
25 public boolean equals(final Object o) {
29 if (o == null || getClass() != o.getClass()) {
33 PrimaryFound that = (PrimaryFound) o;
35 if (!primaryPath.equals(that.primaryPath)) {
43 public int hashCode() {
44 return primaryPath.hashCode();
48 public String toString() {
49 return "PrimaryFound{" +
50 "primaryPath='" + primaryPath + '\'' +
56 public Object toSerializable() {
60 public static PrimaryFound fromSerializable(final Object message){
61 return (PrimaryFound) message;