Interface DHTStorageAdapter
- All Known Implementing Classes:
DHTDBImpl.adapterFacade, DHTPluginStorageManager
public interface DHTStorageAdapter
-
Method Summary
Modifier and TypeMethodDescriptionbyte[][]createNewDiversification(String description, DHTTransportContact cause, byte[] key, boolean put_operation, byte diversification_type, boolean exhaustive_get, int max_depth) byte[][]getExistingDiversification(byte[] key, boolean put_operation, boolean exhaustive_get, int max_depth) getKeyBlockDetails(byte[] key) intbyte[]getKeyForKeyBlock(byte[] request) intintgetNextValueVersions(int num) intintbyte[]getStorageForKey(String key) booleanisDiversified(byte[] key) keyBlockRequest(DHTTransportContact direct_sender, byte[] request, byte[] signature) keyCreated(HashWrapper key, boolean local) Create a new storage key for a given keyvoidkeyDeleted(DHTStorageKey adapter_key) voidkeyRead(DHTStorageKey adapter_key, DHTTransportContact contact) voidsetStorageForKey(String key, byte[] data) voidvalueAdded(DHTStorageKey key, DHTTransportValue value) voidvalueDeleted(DHTStorageKey key, DHTTransportValue value) voidvalueUpdated(DHTStorageKey key, DHTTransportValue old_value, DHTTransportValue new_value)
-
Method Details
-
getNetwork
int getNetwork() -
keyCreated
Create a new storage key for a given key- Returns:
- null if the key shouldn't be allocated (e.g.out of space)
-
keyDeleted
-
keyRead
-
deserialiseStats
- Throws:
IOException
-
valueAdded
-
valueUpdated
-
valueDeleted
-
isDiversified
boolean isDiversified(byte[] key) -
getExistingDiversification
byte[][] getExistingDiversification(byte[] key, boolean put_operation, boolean exhaustive_get, int max_depth) -
createNewDiversification
byte[][] createNewDiversification(String description, DHTTransportContact cause, byte[] key, boolean put_operation, byte diversification_type, boolean exhaustive_get, int max_depth) -
getNextValueVersions
int getNextValueVersions(int num) -
keyBlockRequest
DHTStorageBlock keyBlockRequest(DHTTransportContact direct_sender, byte[] request, byte[] signature) -
getKeyBlockDetails
-
getDirectKeyBlocks
DHTStorageBlock[] getDirectKeyBlocks() -
getKeyForKeyBlock
byte[] getKeyForKeyBlock(byte[] request) -
setStorageForKey
-
getStorageForKey
-
getRemoteFreqDivCount
int getRemoteFreqDivCount() -
getRemoteSizeDivCount
int getRemoteSizeDivCount() -
getKeyCount
int getKeyCount()
-