se.datadosen.util.httpClient
Class HttpResponse

java.lang.Object
  extended by se.datadosen.util.httpClient.HttpResponse

public class HttpResponse
extends java.lang.Object


Constructor Summary
HttpResponse(int statusCode, java.lang.String reason, java.util.Hashtable headers, java.io.InputStream input)
           
 
Method Summary
 java.lang.String getContentAsString()
           
 java.lang.String getHeader(java.lang.String key)
          Get header with specific name
 java.util.Hashtable getHeaders()
          DOCUMENT ME!
 java.io.InputStream getInputStream()
           
 java.lang.String getReasonLine()
           
 int getStatusCode()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

HttpResponse

public HttpResponse(int statusCode,
                    java.lang.String reason,
                    java.util.Hashtable headers,
                    java.io.InputStream input)
             throws java.io.IOException
Throws:
java.io.IOException
Method Detail

getStatusCode

public int getStatusCode()

getReasonLine

public java.lang.String getReasonLine()

getHeaders

public java.util.Hashtable getHeaders()
DOCUMENT ME!

Returns:
Map of uppercase Http headers

getHeader

public java.lang.String getHeader(java.lang.String key)
Get header with specific name

Parameters:
key - name of header. Case is not sensitive
Returns:
value of header

getInputStream

public java.io.InputStream getInputStream()
                                   throws java.io.IOException
Throws:
java.io.IOException

getContentAsString

public java.lang.String getContentAsString()
                                    throws java.io.UnsupportedEncodingException
Throws:
java.io.UnsupportedEncodingException