I want to maintain a list for connected client in on server side using java

Hi ,

I need the help,

Socket incoming=null;

while(true)

{

incoming = s.accept();

if(incoming.isClosed())

{

System.out.println("Disconnected");

}

}

I have to do if client program is terminated then i want to display it on server that this client is not responding.

i.e. I want the updated information of connected client.

[403 byte] By [Lalit1980a] at [2007-11-26 16:06:52]
# 1
> if(incoming.isClosed())This only tells you whether you have closed this socket yourself. An EOF or an exception when doing I/O on the socket tells you that the client has disconnected. You should also set a read timeout on the accepted socket.
ejpa at 2007-7-8 22:29:03 > top of Java-index,Archived Forums,Socket Programming...