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=cc594ca2004f1831568e645e941e517ecb1d43f4;hp=bbfbbaa80b0f5966565f7156725e3eea0c1affcb;hb=8ec73bf853a9b6708b455c0321a585992e02b125;hpb=660a4a4a51718896518b8c4deeeb6e0bb3637bde 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 bbfbbaa80b..cc594ca200 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,32 +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(final 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(final ActorSystem actorSystem,final Object serializable){ - ListenerRegistrationMessages.RegisterChangeListenerReply o = (ListenerRegistrationMessages.RegisterChangeListenerReply) serializable; - return new RegisterChangeListenerReply( - actorSystem.actorFor(o.getListenerRegistrationPath()).path() - ); - } + public ActorPath getListenerRegistrationPath() { + return listenerRegistration.path(); + } }