This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Sockets and Internet Protocols and the fly likes how to check whether a connection is exited? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Sockets and Internet Protocols
Bookmark "how to check whether a connection is exited? " Watch "how to check whether a connection is exited? " New topic
Author

how to check whether a connection is exited?

kahkean chor
Ranch Hand

Joined: Jan 26, 2013
Posts: 56
how to check whether a connection is exited? (socket)
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12761
    
    5
Assuming you mean when the other side of your connection has closed the socket.

For one thing, you will get an IOException when you try to write to it or read from it.

In general, see the java.net.Socket JavaDocs for methods to check state of a socket.

Bill
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how to check whether a connection is exited?
 
Similar Threads
problem in connectivity through datasource to oracle database
nullpointer
how to maintain database using Threads
exit of an object
HTTPS Cipher Threshold