Package com.biglybt.pif.ddb
Interface DistributedDatabase
-
- All Known Implementing Classes:
DDBaseImpl
public interface DistributedDatabase
-
-
Field Summary
Fields Modifier and Type Field Description static int
DHT_AZ_BIGLYBT
static int
DHT_AZ_CVS
static int
DHT_AZ_MAIN
static int
DHT_CVS
Deprecated.use DHT_AZ_CVSstatic int
DHT_MAIN
Deprecated.use DHT_AZ_MAINstatic byte
DT_FREQUENCY
static byte
DT_NONE
static byte
DT_SIZE
static int
OP_EXHAUSTIVE_READ
static int
OP_NONE
static int
OP_PRIORITY_HIGH
-
Method Summary
-
-
-
Field Detail
-
OP_NONE
static final int OP_NONE
- See Also:
- Constant Field Values
-
OP_EXHAUSTIVE_READ
static final int OP_EXHAUSTIVE_READ
- See Also:
- Constant Field Values
-
OP_PRIORITY_HIGH
static final int OP_PRIORITY_HIGH
- See Also:
- Constant Field Values
-
DT_NONE
static final byte DT_NONE
- See Also:
- Constant Field Values
-
DT_FREQUENCY
static final byte DT_FREQUENCY
- See Also:
- Constant Field Values
-
DT_SIZE
static final byte DT_SIZE
- See Also:
- Constant Field Values
-
DHT_MAIN
static final int DHT_MAIN
Deprecated.use DHT_AZ_MAIN- See Also:
- Constant Field Values
-
DHT_CVS
static final int DHT_CVS
Deprecated.use DHT_AZ_CVS- See Also:
- Constant Field Values
-
DHT_AZ_MAIN
static final int DHT_AZ_MAIN
- See Also:
- Constant Field Values
-
DHT_AZ_CVS
static final int DHT_AZ_CVS
- See Also:
- Constant Field Values
-
DHT_AZ_BIGLYBT
static final int DHT_AZ_BIGLYBT
- See Also:
- Constant Field Values
-
-
Method Detail
-
isAvailable
boolean isAvailable()
-
isInitialized
boolean isInitialized()
-
isExtendedUseAllowed
boolean isExtendedUseAllowed()
-
getNetwork
java.lang.String getNetwork()
-
getDHTPlugin
DHTPluginInterface getDHTPlugin()
-
getLocalContact
DistributedDatabaseContact getLocalContact()
-
createKey
DistributedDatabaseKey createKey(java.lang.Object key) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
createKey
DistributedDatabaseKey createKey(java.lang.Object key, java.lang.String description) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
createValue
DistributedDatabaseValue createValue(java.lang.Object value) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
importContact
DistributedDatabaseContact importContact(java.net.InetSocketAddress address) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
importContact
DistributedDatabaseContact importContact(java.net.InetSocketAddress address, byte protocol_version) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
importContact
DistributedDatabaseContact importContact(java.net.InetSocketAddress address, byte protocol_version, int preferred_dht) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
importContact
DistributedDatabaseContact importContact(java.util.Map<java.lang.String,java.lang.Object> map) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
write
void write(DistributedDatabaseListener listener, DistributedDatabaseKey key, DistributedDatabaseValue value) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
write
void write(DistributedDatabaseListener listener, DistributedDatabaseKey key, DistributedDatabaseValue[] values) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
read
void read(DistributedDatabaseListener listener, DistributedDatabaseKey key, long timeout) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
read
void read(DistributedDatabaseListener listener, DistributedDatabaseKey key, long timeout, int options) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
readKeyStats
void readKeyStats(DistributedDatabaseListener listener, DistributedDatabaseKey key, long timeout) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
getValues
java.util.List<DistributedDatabaseValue> getValues(DistributedDatabaseKey key) throws DistributedDatabaseException
Get all locally held (direct+indirect) values for a key- Parameters:
key
-- Returns:
- Throws:
DistributedDatabaseException
-
delete
void delete(DistributedDatabaseListener listener, DistributedDatabaseKey key) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
delete
void delete(DistributedDatabaseListener listener, DistributedDatabaseKey key, DistributedDatabaseContact[] targets) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
addTransferHandler
void addTransferHandler(DistributedDatabaseTransferType type, DistributedDatabaseTransferHandler handler) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
getStandardTransferType
DistributedDatabaseTransferType getStandardTransferType(int standard_type) throws DistributedDatabaseException
- Throws:
DistributedDatabaseException
-
addListener
void addListener(DistributedDatabaseListener l)
-
removeListener
void removeListener(DistributedDatabaseListener l)
-
-