ucr.core
Class NodeConnection
java.lang.Object
ucr.core.Connection
ucr.core.NodeConnection
- All Implemented Interfaces:
- java.lang.Runnable
- public class NodeConnection
- extends Connection
Connection to a servant on the network
Fields inherited from class ucr.core.Connection |
CONNECTION_INCOMING, CONNECTION_OUTGOING, connectionData, DROP_RATE, host, idx, inputCount, inputStream, inputStreamBuffer, outputStream, port, router, shutdownFlag, SIZE, socket, status, STATUS_CONNECTING, STATUS_FAILED, STATUS_OK, STATUS_STOPPED, type |
Method Summary |
private short[] |
getMessage()
|
void |
run()
Connection operation |
Methods inherited from class ucr.core.Connection |
add_query, dumpTable, getConnectedServant, getHost, getHostConnectedServant, getStatus, getType, incr_arrive, queryhits_arrived, send, sendAndReceive, shutdown, startIncomingConnection, startOutgoingConnection |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NodeConnection
NodeConnection(Router router,
java.lang.String host,
int port,
ConnectionData connectionData)
throws java.net.UnknownHostException,
java.io.IOException
- Construct the Connection using host/port information
- Parameters:
router
- message routerhost
- can be a machine name or IP addressport
- port to use
NodeConnection
NodeConnection(Router router,
java.net.Socket socket,
ConnectionData connectionData)
throws java.io.IOException
- Construct the connection with an existing socket
- Parameters:
router
- message routersocket
- socket connection to another servant
getMessage
private short[] getMessage()
run
public void run()
- Connection operation