|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectrice.pastry.PastryNodeFactory
rice.pastry.dist.DistPastryNodeFactory
rice.pastry.rmi.RMIPastryNodeFactory
Pastry node factory for RMI-linked nodes.
Field Summary | |
static int |
DEFAULT_REGISTRY_PORT
|
static int |
NUM_ATTEMPTS
|
static java.rmi.registry.Registry |
rmiRegistry
Instance of RMI registry ever-created when using this factory. |
Fields inherited from class rice.pastry.dist.DistPastryNodeFactory |
PROTOCOL_RMI, PROTOCOL_SOCKET, PROTOCOL_WIRE |
Constructor Summary | |
RMIPastryNodeFactory(NodeIdFactory nf,
int p)
Constructor. |
Method Summary | |
NodeHandle |
generateNodeHandle(java.net.InetSocketAddress address)
Specified by the DistPastryNodeFactory class. |
LeafSet |
getLeafSet(NodeHandle handle)
This method returns the remote leafset of the provided handle to the caller, in a protocol-dependent fashion. |
int |
getProximity(NodeHandle local,
NodeHandle handle)
This method determines and returns the proximity of the current local node the provided NodeHandle. |
RouteSet[] |
getRouteRow(NodeHandle handle,
int row)
This method returns the remote route row of the provided handle to the caller, in a protocol-dependent fashion. |
PastryNode |
newNode(NodeHandle bootstrap)
Generates a new pastry node with a random NodeId using the bootstrap bootstrap. |
PastryNode |
newNode(NodeHandle bootstrap,
NodeId nodeId)
Makes many policy choices and manufactures a new RMIPastryNode. |
void |
pause(int ms)
Pauses the current thread for ms milliseconds. |
Methods inherited from class rice.pastry.dist.DistPastryNodeFactory |
getFactory, getNodeHandle |
Methods inherited from class rice.pastry.PastryNodeFactory |
getNearest |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static int NUM_ATTEMPTS
public static int DEFAULT_REGISTRY_PORT
public static java.rmi.registry.Registry rmiRegistry
Constructor Detail |
public RMIPastryNodeFactory(NodeIdFactory nf, int p)
p
- RMI registry port.Method Detail |
public NodeHandle generateNodeHandle(java.net.InetSocketAddress address)
generateNodeHandle
in class DistPastryNodeFactory
address
- The address to look for the node.
public void pause(int ms)
ms
- The number of milliseconds to pause.public PastryNode newNode(NodeHandle bootstrap)
DistPastryNodeFactory
newNode
in class DistPastryNodeFactory
bootstrap
- Node handle to bootstrap from.
public PastryNode newNode(NodeHandle bootstrap, NodeId nodeId)
newNode
in class DistPastryNodeFactory
bootstrap
- Node handle to bootstrap from.nodeId
- DESCRIBE THE PARAMETER
public LeafSet getLeafSet(NodeHandle handle)
getLeafSet
in class PastryNodeFactory
handle
- The node to connect to
public RouteSet[] getRouteRow(NodeHandle handle, int row)
getRouteRow
in class PastryNodeFactory
handle
- The node to connect torow
- The row number to retrieve
public int getProximity(NodeHandle local, NodeHandle handle)
getProximity
in class PastryNodeFactory
handle
- The handle to determine the proximity of
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |