jsky.util
Class ConnectionUtil
java.lang.Object
jsky.util.ConnectionUtil
public class ConnectionUtil
- extends Object
A utility class for getting a URL connection in a background thread
without hanging. Used to solve the problem of a background thread
hanging (even after calling Thread.interrupt()) while waiting for
URL.openConnection() to return.
- Version:
- $Revision: 1.5 $
- Author:
- Allan Brighton
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ConnectionUtil
public ConnectionUtil(URL url)
- Initialize with the given URL
openConnection
public URLConnection openConnection()
throws IOException
- Throws:
IOException
interrupt
public void interrupt()
- Interrupt the connection
Copyright © 2015 Central Laboratory of the Research Councils. All Rights Reserved.