rice.pastry.socket
Class SocketPastryNodeFactory
java.lang.Object
rice.pastry.PastryNodeFactory
rice.pastry.transport.TransportPastryNodeFactory
rice.pastry.socket.SocketPastryNodeFactory
public class SocketPastryNodeFactory
- extends TransportPastryNodeFactory
Pastry node factory for Socket-linked nodes.
- Version:
- $Id: SocketPastryNodeFactory.java,v 1.6 2004/03/08 19:53:57 amislove
Exp $
- Author:
- Alan Mislove
Methods inherited from class rice.pastry.transport.TransportPastryNodeFactory |
getLeafSet, getLeafSet, getProximity, getRouteRow, getRouteRow, newNode, newNode, newNode, newNode, newNode, newNode |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
SocketPastryNodeFactory
public SocketPastryNodeFactory(NodeIdFactory nf,
int startPort,
Environment env)
throws java.io.IOException
- Throws:
java.io.IOException
SocketPastryNodeFactory
public SocketPastryNodeFactory(NodeIdFactory nf,
java.net.InetAddress bindAddress,
int startPort,
Environment env,
NATHandler handler)
throws java.io.IOException
- Throws:
java.io.IOException
getNodeHandle
public NodeHandle getNodeHandle(java.net.InetSocketAddress bootstrap,
int i)
getNodeHandle
public NodeHandle getNodeHandle(java.net.InetSocketAddress bootstrap)
getNodeHandle
public void getNodeHandle(java.net.InetSocketAddress[] bootstraps,
Continuation c)
getNodeHandle
public NodeHandle getNodeHandle(java.net.InetSocketAddress[] bootstraps,
int int1)
newNode
public PastryNode newNode(NodeHandle nodeHandle,
Id id,
java.net.InetSocketAddress proxyAddress)
- Description copied from class:
TransportPastryNodeFactory
- Method which creates a Pastry node from the next port with the specified nodeId
(or one generated from the NodeIdFactory if not specified)
- Overrides:
newNode
in class TransportPastryNodeFactory
- Parameters:
nodeHandle
- Node handle to bootstrap from.id
- if non-null, will use this nodeId for the node, rather than using the NodeIdFactory
- Returns:
- A node with a random ID and next port number.
verifyConnection
public static java.net.InetSocketAddress verifyConnection(int i,
java.net.InetSocketAddress addr,
java.net.InetSocketAddress[] addr2,
Environment env,
Logger l)
Copyright © 2001-2005 - Rice Pastry.