All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class webwisdom.tango.fake.TServerFake

java.lang.Object
   |
   +----webwisdom.tango.fake.TServerFake

public class TServerFake
extends Object
Simple server broadcasting messages from clients to all other clients. Clients are instances of FakeTangoAgent. Run with parameter being a port number. Console communicates have two formats:

See Also:
FakeTangoAgent

Variable Index

 o DATA
 o MASTER
 o SLAVE

Constructor Index

 o TServerFake(int)
Anchors at the given port.

Method Index

 o main(String[])
Creates and starts the server at the port given the first parameter.
 o run()
Starts the server.
 o toString()

Variables

 o DATA
 public static final byte DATA
 o MASTER
 public static final byte MASTER
 o SLAVE
 public static final byte SLAVE

Constructors

 o TServerFake
 public TServerFake(int port) throws IOException
Anchors at the given port.

Parameters:
port - port at which the server is to listen for clients
Throws: IOException
if cannot start service at given port

Methods

 o run
 public void run() throws IOException
Starts the server. Servers accepts connections from clients and creates new thread for each client.

Throws: IOException
not caught system exceptions
 o toString
 public String toString()
Overrides:
toString in class Object
 o main
 public static void main(String args[])
Creates and starts the server at the port given the first parameter.


All Packages  Class Hierarchy  This Package  Previous  Next  Index