com.jalios.io
Class HttpClient
java.lang.Object
com.jalios.io.HttpClient
public class HttpClient
- extends java.lang.Object
|
Method Summary |
boolean |
connect(java.lang.String url)
Initialise a Connection to a given URL |
java.lang.String |
getContents(java.lang.String url)
Connect, get the content and disconnect. |
java.lang.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 |
REVISION
public static final java.lang.String REVISION
- See Also:
- Constant Field Values
SET_COOKIE
public static final java.lang.String SET_COOKIE
- See Also:
- Constant Field Values
JSESSSIONID
public static final java.lang.String JSESSSIONID
- See Also:
- Constant Field Values
connection
protected java.net.HttpURLConnection connection
cookie
protected java.lang.String cookie
responseCode
protected int responseCode
HttpClient
public HttpClient()
connect
public boolean connect(java.lang.String url)
- Initialise a Connection to a given URL
- Parameters:
url -
- Returns:
- true if the connection is Ok
getContents
public java.lang.String getContents(java.lang.String url)
- Connect, get the content and disconnect.
- Parameters:
url -
- Returns:
- the content
readCookie
public java.lang.String readCookie()
throws java.io.IOException
- Return the value of the cookie
- Returns:
- the cookie
- Throws:
java.io.IOException
Copyright © 2001-2010 Jalios SA. All Rights Reserved.