Package net.tomp2p.dht

Examples of net.tomp2p.dht.PeerDHT.bootstrap()


          }
    } else {
      final Peer peer = new PeerBuilder(Number160.createHash("client")).ports(1235).start();
            List<PeerAddress> bootstrap = new ArrayList<PeerAddress>();
            bootstrap.add(new PeerAddress(Number160.createHash("master"), "localhost", 1234,1234));
            peer.bootstrap().bootstrapTo(bootstrap).start();

            peer.objectDataReply(new ObjectDataReply() {
                public Object reply(PeerAddress sender, Object request) throws Exception {
                    System.err.println("client received: " + request.toString());
                    return "pong";
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.