public class ChatServer extends Frame
{
TextArea ta = new TextArea();
public void launchFrame()
{
add(ta, BorderLayout.CENTER);
setBounds(0,0,200,300);
this.addWindowListener(
new WindowAdapter()
{
public void windowClosing(WindowEvent e)
{
System.exit(0);
}
}
);
setVisible(true);
}
ServerSocket server = null;
Collection cClient = new ArrayList();
public ChatServer(int port) throws Exception
{
server = new ServerSocket(port);
launchFrame();
}