|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface DKSDHTInterface
An important concept used by this interface is that the value bound to a key using the DKS DHT should be treated as an array of DKSObject, and that it shall be possible to modify this array atomically. The DKSObject structure consists of arbitrary contents represented by a java.lang.Object, along with an integer content identifier. Two DKSObject are considered equal if they have equal content identifiers. Keys are represented by long (64 bit) integers in this interface. It is up to other services using this interface to translate application specific keys to this representation.
| Method Summary | |
|---|---|
void |
addToBinding(long key,
DKSObject value)
Value is added to the list of bindings associated with key. |
void |
broadcast(DKSObject message)
Broadcast a message to all nodes |
void |
changeBinding(long key,
DKSObject oldValue,
DKSObject newValue)
All ocurrences of oldValue in the bindings associated with key are replaced by newValue. |
DKSObject[] |
lookupBinding(long key)
Returns a vector of DKSObjects associated with key
in the DHT |
DKSObject[] |
lookupBinding(long minKey,
long maxKey)
Returns a list of all bindings associated with keys greater than or equal to minKey, and less than or equal to maxKey. |
void |
removeFromBinding(long key,
DKSObject value)
Value is removed from the list of bindings associated with key. |
| Methods inherited from interface org.kth.dks.DKSInterface |
|---|
addMsgHandler, broadcastRestricted, create, findResponsible, getDKSRef, getDKSURL, join, leave, logLevel, route, routeAsync, routeAsyncFrom, send, unregisterNode |
| Method Detail |
|---|
void addToBinding(long key,
DKSObject value)
void removeFromBinding(long key,
DKSObject value)
void changeBinding(long key,
DKSObject oldValue,
DKSObject newValue)
DKSObject[] lookupBinding(long key)
key
in the DHT
key - long specifying the key to be looked up
DKSObject[] with values associated to
key
DKSObject[] lookupBinding(long minKey,
long maxKey)
void broadcast(DKSObject message)
broadcast in interface DKSInterface
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||