org.gudy.azureus2.plugins.ddb
Interface DistributedDatabaseContact


public interface DistributedDatabaseContact

Author:
parg

Method Summary
 java.net.InetSocketAddress getAddress()
           
 java.lang.String getName()
           
 boolean isAlive(long timeout)
           
 boolean isOrHasBeenLocal()
           
 boolean openTunnel()
          Tries to open a NAT tunnel to the contact.
 DistributedDatabaseValue read(DistributedDatabaseProgressListener listener, DistributedDatabaseTransferType type, DistributedDatabaseKey key, long timeout)
           
 void write(DistributedDatabaseTransferType type, DistributedDatabaseKey key, DistributedDatabaseValue data)
           
 

Method Detail

getName

java.lang.String getName()

getAddress

java.net.InetSocketAddress getAddress()

isAlive

boolean isAlive(long timeout)

isOrHasBeenLocal

boolean isOrHasBeenLocal()

openTunnel

boolean openTunnel()
Tries to open a NAT tunnel to the contact. Should only be used if direct contact fails

Returns:

write

void write(DistributedDatabaseTransferType type,
           DistributedDatabaseKey key,
           DistributedDatabaseValue data)
           throws DistributedDatabaseException
Throws:
DistributedDatabaseException

read

DistributedDatabaseValue read(DistributedDatabaseProgressListener listener,
                              DistributedDatabaseTransferType type,
                              DistributedDatabaseKey key,
                              long timeout)
                              throws DistributedDatabaseException
Throws:
DistributedDatabaseException