tomp2p / TomP2P

A P2P-based high performance key-value pair storage library
http://tomp2p.net
Apache License 2.0
441 stars 123 forks source link

Allow to set PublicPrivate KeyPair after building peer #123

Open rmatil opened 8 years ago

rmatil commented 8 years ago

Currently, the key-pair has to be set while creating the peerDHT:


this.peerDht = new PeerBuilderDHT(
                    new PeerBuilder(new Number160(rnd))
                            .keyPair(this.user.getKeyPair())
                            .ports(this.config.getPort())
                            .bindings(this.bindings)
                            .start()
            ).start();

It would be nice to be able to set the key pair after initiating the peer dht.