X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fmd-sal%2Fsal-distributed-datastore%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fcluster%2Fdatastore%2Fmessages%2FRegisterChangeListenerReply.java;h=f7031e4e379e7954dc728122baf763abd7469098;hp=8d980d283db9c9187733e44c4f685287c83a97ea;hb=bfbc7893038987db21ed3ec5970a6de1c2a655de;hpb=1e59825dbec7b354d76bd7efa6a61e4ad802c802 diff --git a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/RegisterChangeListenerReply.java b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/RegisterChangeListenerReply.java index 8d980d283d..f7031e4e37 100644 --- a/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/RegisterChangeListenerReply.java +++ b/opendaylight/md-sal/sal-distributed-datastore/src/main/java/org/opendaylight/controller/cluster/datastore/messages/RegisterChangeListenerReply.java @@ -9,31 +9,16 @@ package org.opendaylight.controller.cluster.datastore.messages; import akka.actor.ActorPath; -import akka.actor.ActorSystem; -import org.opendaylight.controller.protobuff.messages.registration.ListenerRegistrationMessages; +import akka.actor.ActorRef; -public class RegisterChangeListenerReply implements SerializableMessage{ - public static final Class SERIALIZABLE_CLASS = ListenerRegistrationMessages.RegisterChangeListenerReply.class; - private final ActorPath listenerRegistrationPath; +public class RegisterChangeListenerReply { + private final ActorRef listenerRegistration; - public RegisterChangeListenerReply(ActorPath listenerRegistrationPath) { - this.listenerRegistrationPath = listenerRegistrationPath; - } + public RegisterChangeListenerReply(final ActorRef listenerRegistration) { + this.listenerRegistration = listenerRegistration; + } - public ActorPath getListenerRegistrationPath() { - return listenerRegistrationPath; - } - - @Override - public ListenerRegistrationMessages.RegisterChangeListenerReply toSerializable() { - return ListenerRegistrationMessages.RegisterChangeListenerReply.newBuilder() - .setListenerRegistrationPath(listenerRegistrationPath.toString()).build(); - } - - public static RegisterChangeListenerReply fromSerializable(ActorSystem actorSystem,Object serializable){ - ListenerRegistrationMessages.RegisterChangeListenerReply o = (ListenerRegistrationMessages.RegisterChangeListenerReply) serializable; - return new RegisterChangeListenerReply( - actorSystem.actorFor(o.getListenerRegistrationPath()).path() - ); - } + public ActorPath getListenerRegistrationPath() { + return listenerRegistration.path(); + } }