# Class WarURLConnection

java.lang.Object
java.net.URLConnection
org.apache.catalina.webresources.war.WarURLConnection

public class WarURLConnection extends URLConnection
URL connection for WAR resources that wraps a JAR URL connection.

## Field Summary

### Fields inherited from class URLConnection

`allowUserInteraction, doInput, doOutput, ifModifiedSince, url, useCaches`

## Constructor Summary

Constructors
Modifier
Constructor
Description
`protected`
`WarURLConnection(URL url)`
Constructs a new WarURLConnection.

## Method Summary

Modifier and Type
Method
Description
`void`
`connect()`
`int`
`getContentLength()`
`long`
`getContentLengthLong()`
`InputStream`
`getInputStream()`
`long`
`getLastModified()`
`Permission`
`getPermission()`
Deprecated.

### Methods inherited from class URLConnection

`addRequestProperty, getAllowUserInteraction, getConnectTimeout, getContent, getContent, getContentEncoding, getContentType, getDate, getDefaultAllowUserInteraction, getDefaultRequestProperty, getDefaultUseCaches, getDefaultUseCaches, getDoInput, getDoOutput, getExpiration, getFileNameMap, getHeaderField, getHeaderField, getHeaderFieldDate, getHeaderFieldInt, getHeaderFieldKey, getHeaderFieldLong, getHeaderFields, getIfModifiedSince, getOutputStream, getReadTimeout, getRequestProperties, getRequestProperty, getURL, getUseCaches, guessContentTypeFromName, guessContentTypeFromStream, setAllowUserInteraction, setConnectTimeout, setContentHandlerFactory, setDefaultAllowUserInteraction, setDefaultRequestProperty, setDefaultUseCaches, setDefaultUseCaches, setDoInput, setDoOutput, setFileNameMap, setIfModifiedSince, setReadTimeout, setRequestProperty, setUseCaches, toString`

### Methods inherited from class Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Constructor Details

### WarURLConnection

protected WarURLConnection(URL url) throws IOException
Constructs a new WarURLConnection.

Parameters:
  `url` - The URL to connect to
Throws:
  `IOException` - If an I/O error occurs

## Method Details

### connect

public void connect() throws IOException

Specified by:
  `connect` in class `URLConnection`
Throws:
  `IOException`

### getInputStream

public InputStream getInputStream() throws IOException

Overrides:
  `getInputStream` in class `URLConnection`
Throws:
  `IOException`

### getPermission

@Deprecated public Permission getPermission() throws IOException
Deprecated.

Overrides:
  `getPermission` in class `URLConnection`
Throws:
  `IOException`

### getLastModified

public long getLastModified()

Overrides:
  `getLastModified` in class `URLConnection`

### getContentLength

public int getContentLength()

Overrides:
  `getContentLength` in class `URLConnection`

### getContentLengthLong

public long getContentLengthLong()

Overrides:
  `getContentLengthLong` in class `URLConnection`