netP5
Class TcpServer

java.lang.Object
  extended by netP5.AbstractTcpServer
      extended by netP5.TcpServer
All Implemented Interfaces:
Runnable, TcpPacketListener

public class TcpServer
extends AbstractTcpServer

Author:
andreas schlegel

Field Summary
 
Fields inherited from class netP5.AbstractTcpServer
MODE_NEWLINE, MODE_READLINE, MODE_STREAM, MODE_TERMINATED
 
Constructor Summary
TcpServer(int thePort)
           
TcpServer(int thePort, int theMode)
           
TcpServer(Object theObject, int thePort)
           
TcpServer(Object theObject, int thePort, int theMode)
           
TcpServer(TcpPacketListener theTcpPacketListener, int thePort, int theMode)
           
 
Method Summary
 void addListener(NetListener theListener)
           
 NetListener getListener(int theIndex)
           
 Vector getListeners()
           
 void handleInput(TcpPacket thePacket, int thePort)
           
 void removeListener(NetListener theListener)
           
 void status(int theIndex)
           
 
Methods inherited from class netP5.AbstractTcpServer
ban, dispose, getClient, getClients, process, remove, run, send, send, size, socket, unBan
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TcpServer

public TcpServer(int thePort)
Parameters:
thePort - int

TcpServer

public TcpServer(Object theObject,
                 int thePort)
Parameters:
theObject - Object
thePort - int

TcpServer

public TcpServer(Object theObject,
                 int thePort,
                 int theMode)
Parameters:
theObject - Object
thePort - int
theMode - int

TcpServer

public TcpServer(int thePort,
                 int theMode)
Parameters:
thePort - int
theMode - int

TcpServer

public TcpServer(TcpPacketListener theTcpPacketListener,
                 int thePort,
                 int theMode)
Parameters:
theTcpPacketListener - TcpPacketListener
thePort - int
theMode - int
Method Detail

handleInput

public void handleInput(TcpPacket thePacket,
                        int thePort)
Specified by:
handleInput in class AbstractTcpServer
Parameters:
thePacket - TcpPacket
thePort - int

status

public void status(int theIndex)
Parameters:
theIndex - int

addListener

public void addListener(NetListener theListener)

removeListener

public void removeListener(NetListener theListener)

getListener

public NetListener getListener(int theIndex)

getListeners

public Vector getListeners()


processing library oscP5 by Andreas Schlegel. (c) 2004-2011