org.placelab.proxy
Class SocketServer

java.lang.Object
  extended byorg.placelab.proxy.SocketServer
All Implemented Interfaces:
java.lang.Runnable
Direct Known Subclasses:
HTTPServer, ProxyServer

public abstract class SocketServer
extends java.lang.Object
implements java.lang.Runnable


Constructor Summary
SocketServer(int port, int threadCount)
           
SocketServer(int port, int threadCount, java.lang.String label)
           
 
Method Summary
 long getNumberOfConnections()
           
 int getPort()
           
 long getStartTimeMillis()
           
 org.placelab.proxy.SocketServer.SocketWorker getWorker()
           
 void run()
           
abstract  void serviceSocket(java.net.Socket s)
           
 void startServer()
           
 void stopServer()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SocketServer

public SocketServer(int port,
                    int threadCount)

SocketServer

public SocketServer(int port,
                    int threadCount,
                    java.lang.String label)
Method Detail

startServer

public void startServer()
                 throws java.lang.Exception
Throws:
java.lang.Exception

stopServer

public void stopServer()

getWorker

public org.placelab.proxy.SocketServer.SocketWorker getWorker()

run

public void run()
Specified by:
run in interface java.lang.Runnable

serviceSocket

public abstract void serviceSocket(java.net.Socket s)

getNumberOfConnections

public long getNumberOfConnections()

getStartTimeMillis

public long getStartTimeMillis()

getPort

public int getPort()