Package com.biglybt.pif.ddb
Interface DistributedDatabaseContact
-
- All Known Implementing Classes:
DDBaseContactImpl
public interface DistributedDatabaseContact
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description DistributedDatabaseValue
call(DistributedDatabaseProgressListener listener, DistributedDatabaseTransferType type, DistributedDatabaseValue data, long timeout)
java.util.Map<java.lang.String,java.lang.Object>
exportToMap()
java.net.InetSocketAddress
getAddress()
byte[]
getID()
java.lang.String
getName()
int
getNetwork()
int
getVersion()
boolean
isAlive(long timeout)
void
isAlive(long timeout, DistributedDatabaseListener listener)
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(DistributedDatabaseProgressListener listener, DistributedDatabaseTransferType type, DistributedDatabaseKey key, DistributedDatabaseValue data, long timeout)
-
-
-
Method Detail
-
getID
byte[] getID()
-
getName
java.lang.String getName()
-
getVersion
int getVersion()
-
getAddress
java.net.InetSocketAddress getAddress()
-
getNetwork
int getNetwork()
-
isAlive
boolean isAlive(long timeout)
-
isAlive
void isAlive(long timeout, DistributedDatabaseListener listener)
-
isOrHasBeenLocal
boolean isOrHasBeenLocal()
-
exportToMap
java.util.Map<java.lang.String,java.lang.Object> exportToMap()
-
openTunnel
boolean openTunnel()
Tries to open a NAT tunnel to the contact. Should only be used if direct contact fails- Returns:
-
call
DistributedDatabaseValue call(DistributedDatabaseProgressListener listener, DistributedDatabaseTransferType type, DistributedDatabaseValue data, long timeout) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
write
void write(DistributedDatabaseProgressListener listener, DistributedDatabaseTransferType type, DistributedDatabaseKey key, DistributedDatabaseValue data, long timeout) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
read
DistributedDatabaseValue read(DistributedDatabaseProgressListener listener, DistributedDatabaseTransferType type, DistributedDatabaseKey key, long timeout) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
-