com.jalios.io
Class HttpClient

java.lang.Object
  extended by com.jalios.io.HttpClient

public class HttpClient
extends Object


Field Summary
protected  HttpURLConnection connection
           
protected  String cookie
           
static String JSESSSIONID
           
protected  int responseCode
           
static String REVISION
           
static String SET_COOKIE
           
 
Constructor Summary
HttpClient()
           
 
Method Summary
 boolean connect(String url)
          Initialise a Connection to a given URL
 String getContents(String url)
          Connect, get the content and disconnect.
 String readCookie()
          Return the value of the cookie
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

REVISION

public static final String REVISION
See Also:
Constant Field Values

SET_COOKIE

public static final String SET_COOKIE
See Also:
Constant Field Values

JSESSSIONID

public static final String JSESSSIONID
See Also:
Constant Field Values

connection

protected HttpURLConnection connection

cookie

protected String cookie

responseCode

protected int responseCode
Constructor Detail

HttpClient

public HttpClient()
Method Detail

connect

public boolean connect(String url)
Initialise a Connection to a given URL

Parameters:
url -
Returns:
true if the connection is Ok

getContents

public String getContents(String url)
Connect, get the content and disconnect.

Parameters:
url -
Returns:
the content

readCookie

public String readCookie()
                  throws IOException
Return the value of the cookie

Returns:
the cookie
Throws:
IOException


Copyright © 2001-2010 Jalios SA. All Rights Reserved.