public class Connections extends Object
URLConnection related utilities| Modifier and Type | Method and Description |
|---|---|
static void |
close(URLConnection connection)
Closes a connection
|
static void |
closeQuietly(URLConnection connection)
Closes a connection, ignoring any exceptions if they occur
|
static Time |
getLastModified(URL url)
Gets last modified date of the given
URL |
public static Time getLastModified(URL url) throws IOException
URLurl - null if not availableIOExceptionpublic static void closeQuietly(URLConnection connection)
connection - public static void close(URLConnection connection) throws IOException
connection - IOExceptionCopyright © 2006–2021 Apache Software Foundation. All rights reserved.