Package org.openstreetmap.josm.tools
Class Http1Client.Http1Response
java.lang.Object
org.openstreetmap.josm.tools.HttpClient.Response
org.openstreetmap.josm.tools.Http1Client.Http1Response
- Enclosing class:
- Http1Client
A wrapper for the HTTP 1.x response.
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivateHttp1Response(HttpURLConnection connection, ProgressMonitor progressMonitor) -
Method Summary
Modifier and TypeMethodDescriptionvoidIndicates that other requests to the server are unlikely in the near future.Returns theContent-Encodingheader.longReturns theContent-Lengthheader.Returns theContent-Typeheader.longReturns theExpireheader.getHeaderField(String name) Returns the value of the named header field.Returns an unmodifiable Map mapping header keys to a List of header values.longReturns theLast-Modifiedheader.Returns the request method.getURL()Returns the URL.Methods inherited from class org.openstreetmap.josm.tools.HttpClient.Response
debugRedirect, fetchContent, getContent, getContentReader, getResponseCode, getResponseMessage, uncompress, uncompressAccordingToContentDisposition
-
Field Details
-
connection
-
-
Constructor Details
-
Http1Response
private Http1Response(HttpURLConnection connection, ProgressMonitor progressMonitor) throws IOException - Throws:
IOException
-
-
Method Details
-
getURL
Description copied from class:HttpClient.ResponseReturns the URL.- Specified by:
getURLin classHttpClient.Response- Returns:
- the URL
- See Also:
-
getRequestMethod
Description copied from class:HttpClient.ResponseReturns the request method.- Specified by:
getRequestMethodin classHttpClient.Response- Returns:
- the HTTP request method
- See Also:
-
getInputStream
- Specified by:
getInputStreamin classHttpClient.Response- Throws:
IOException
-
getContentEncoding
Description copied from class:HttpClient.ResponseReturns theContent-Encodingheader.- Specified by:
getContentEncodingin classHttpClient.Response- Returns:
Content-EncodingHTTP header- See Also:
-
getContentType
Description copied from class:HttpClient.ResponseReturns theContent-Typeheader.- Specified by:
getContentTypein classHttpClient.Response- Returns:
Content-TypeHTTP header- See Also:
-
getExpiration
Description copied from class:HttpClient.ResponseReturns theExpireheader.- Specified by:
getExpirationin classHttpClient.Response- Returns:
ExpireHTTP header- See Also:
-
getLastModified
Description copied from class:HttpClient.ResponseReturns theLast-Modifiedheader.- Specified by:
getLastModifiedin classHttpClient.Response- Returns:
Last-ModifiedHTTP header- See Also:
-
getContentLength
Description copied from class:HttpClient.ResponseReturns theContent-Lengthheader.- Specified by:
getContentLengthin classHttpClient.Response- Returns:
Content-LengthHTTP header- See Also:
-
getHeaderField
Description copied from class:HttpClient.ResponseReturns the value of the named header field.- Specified by:
getHeaderFieldin classHttpClient.Response- Parameters:
name- the name of a header field- Returns:
- the value of the named header field, or
nullif there is no such field in the header - See Also:
-
getHeaderFields
Description copied from class:HttpClient.ResponseReturns an unmodifiable Map mapping header keys to a List of header values. As per RFC 2616, section 4.2 header names are case insensitive, so returned map is also case insensitive- Specified by:
getHeaderFieldsin classHttpClient.Response- Returns:
- unmodifiable Map mapping header keys to a List of header values
- See Also:
-
disconnect
Description copied from class:HttpClient.ResponseIndicates that other requests to the server are unlikely in the near future.- Specified by:
disconnectin classHttpClient.Response- See Also:
-