|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Method Summary | |
Id |
getId()
Returns this node's id, which is its identifier in the namespace. |
NodeHandle |
getLocalNodeHandle()
Returns a handle to the local node below this endpoint. |
NodeHandleSet |
localLookup(Id id,
int num,
boolean safe)
This call produces a list of nodes that can be used as next hops on a route towards the given id, such that the resulting route satisfies the overlay protocol's bounds on the number of hops taken. |
NodeHandleSet |
neighborSet(int num)
This methods returns an unordered set of nodehandles on which are neighbors of the local node in the id space. |
IdRange |
range(NodeHandle handle,
int rank,
Id lkey)
This operation provides information about ranges of keys for which the node is currently a rank-root. |
IdRange |
range(NodeHandle handle,
int rank,
Id lkey,
boolean cumulative)
This operation provides information about ranges of keys for which the node is currently a rank-root. |
NodeHandleSet |
replicaSet(Id id,
int maxRank)
This methods returns an ordered set of nodehandles on which replicas of an object with a given id can be stored. |
void |
route(Id id,
Message message,
NodeHandle hint)
This method makes an attempt to route the message to the root of the given id. |
java.util.TimerTask |
scheduleMessage(Message message,
long delay)
Schedules a message to be delivered to this application after the provided number of milliseconds. |
java.util.TimerTask |
scheduleMessage(Message message,
long delay,
long period)
Schedules a message to be delivered to this application every period number of milliseconds, after delay number of miliseconds have passed. |
Method Detail |
public Id getId()
public void route(Id id, Message message, NodeHandle hint)
id
- The destination Id of the message.message
- The message to deliverhint
- The first node to send this message to, optionalpublic NodeHandleSet localLookup(Id id, int num, boolean safe)
id
- The destination id.num
- The number of nodes to return.safe
- Whether or not to return safe nodes.public NodeHandleSet neighborSet(int num)
num
- The number of desired handle to return.public NodeHandleSet replicaSet(Id id, int maxRank)
id
- The object's id.maxRank
- The number of desired replicas.public IdRange range(NodeHandle handle, int rank, Id lkey)
handle
- The handle whose range to check.rank
- The root rank.lkey
- An "index" in case of multiple ranges.public IdRange range(NodeHandle handle, int rank, Id lkey, boolean cumulative)
handle
- The handle whose range to check.rank
- The root rank.lkey
- An "index" in case of multiple ranges.cumulative
- Whether to return the cumulative or single rangepublic NodeHandle getLocalNodeHandle()
public java.util.TimerTask scheduleMessage(Message message, long delay)
message
- The message to be delivereddelay
- The number of milliseconds to wait before delivering the messagepublic java.util.TimerTask scheduleMessage(Message message, long delay, long period)
message
- The message to be delivereddelay
- The number of milliseconds to wait before delivering the fist message
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |