|
Rice Pastry API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.util.Observable rice.p2p.commonapi.NodeHandle rice.pastry.NodeHandle rice.pastry.dist.DistNodeHandle
Abstract class for handles to "real" remote nodes. This class abstracts out the node handle verification which is necessary in the "real" pastry protocols, since NodeHandles are sent across the wire.
Field Summary | |
protected java.net.InetSocketAddress |
address
DESCRIBE THE FIELD |
protected int |
epoch
a unique number matching the liveness of this node this number will be different each time the process is run, but the NodeId can be the same. |
protected Id |
nodeId
DESCRIBE THE FIELD |
Fields inherited from class rice.pastry.NodeHandle |
LIVENESS_ALIVE, LIVENESS_DEAD, LIVENESS_SUSPECTED, localnode, logger |
Fields inherited from class rice.p2p.commonapi.NodeHandle |
DECLARED_DEAD, DECLARED_LIVE, PROXIMITY_CHANGED |
Constructor Summary | |
DistNodeHandle(Id nodeId,
java.net.InetSocketAddress address)
Constructor |
Method Summary | |
abstract boolean |
equals(java.lang.Object obj)
Equivalence relation for nodehandles. |
java.net.InetSocketAddress |
getAddress()
Returns the IP address and port of the remote node. |
int |
getEpoch()
Gets the epoch or session identifier of this Pastry node. |
Id |
getNodeId()
Gets the nodeId of this Pastry node. |
abstract int |
hashCode()
Hash codes for node handles. |
abstract java.lang.String |
toString()
Returns a String representation of this DistNodeHandle. |
Methods inherited from class rice.pastry.NodeHandle |
assertLocalNode, bootstrap, checkLiveness, getId, getLiveness, getLocalNode, isAlive, ping, proximity, receiveMessage, serialize |
Methods inherited from class java.util.Observable |
addObserver, clearChanged, countObservers, deleteObserver, deleteObservers, hasChanged, notifyObservers, notifyObservers, setChanged |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.Observer |
update |
Field Detail |
protected Id nodeId
protected java.net.InetSocketAddress address
protected int epoch
Constructor Detail |
public DistNodeHandle(Id nodeId, java.net.InetSocketAddress address)
nodeId
- This node handle's node Id.address
- DESCRIBE THE PARAMETERMethod Detail |
public final Id getNodeId()
getNodeId
in class NodeHandle
public int getEpoch()
public final java.net.InetSocketAddress getAddress()
public abstract java.lang.String toString()
public abstract boolean equals(java.lang.Object obj)
equals
in class NodeHandle
obj
- the other nodehandle .
public abstract int hashCode()
hashCode
in class NodeHandle
|
Rice Pastry API | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |