Examples of OriginMessage


Examples of org.planx.routing.kademlia.operation.OriginMessage

    public void receive(Message incoming, int comm) throws IOException,
                                               UnknownMessageException {
        super.receive(incoming, comm);

        QueueMessage myMessage = (QueueMessage) incoming;
        OriginMessage mess = (OriginMessage) incoming;
      System.out.println("TestReceiver.java: TestMessage \""+myMessage.toString()+ "\" recieved at " + local.toString() + " from " + mess.getOrigin());
        Node origin = mess.getOrigin();       
        //List nodes = space.getClosestNodes(mess.getLookupId());
        Message reply = new InReplyMessage(local,"","Test");
        server.reply(comm, reply, origin.getInetAddress(), origin.getPort());
        System.out.println("ReplyMessage sent to " + origin.toString() + " from " + local.toString());
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.