I want an event when program I'm connected with closes Socket
opalpa_at_gmail.com
Date: 01/12/05
- Next message: Jacob: "Re: How to print a pdf/any file from Java"
- Previous message: Steve Horsley: "Re: Why does socket:read() take so long to determine broken connection?"
- Next in thread: Esmond Pitt: "Re: I want an event when program I'm connected with closes Socket"
- Reply: Esmond Pitt: "Re: I want an event when program I'm connected with closes Socket"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 12 Jan 2005 14:09:06 -0800
I've written socket code previously and am confronted with a new
situation: I have a server which manages multiple connections and each
connections can be reused for multiple messages. The client does not
say anything before closing, it just closes. What is the correct way
to determine that client closed socket?
I've looked at java.net.socket 1.5 documentation and it is much too
imprecise for my understanding. Like does isClosed() mean that close()
was called on instance? Does it mean that specific symbols were
received by instance from client?
It seems that more commonly protocols have explicit messages informing
of closing, however in my circumstances changing protocols is not an
option.
Looking forward to replies.
- Next message: Jacob: "Re: How to print a pdf/any file from Java"
- Previous message: Steve Horsley: "Re: Why does socket:read() take so long to determine broken connection?"
- Next in thread: Esmond Pitt: "Re: I want an event when program I'm connected with closes Socket"
- Reply: Esmond Pitt: "Re: I want an event when program I'm connected with closes Socket"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|
|