|
Oracle® XML Java API Reference 10g Release 1 (10.1) B12024-02 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.soap.transport.http.Cookie
A cookie as defined in RFC 2109 and RFC 2965. Since cookie support is a relatively tangential feature, this implementation is very forgiving, allowing many variations from the RFCs and staying mum regarding errors. This class also provides static methods to support management of an array of Cookie
instances.
Constructor Summary | |
Cookie(java.net.URL url, java.lang.String cookieString) Creates an instance from a cookie string. |
Method Summary | |
static java.lang.String |
buildCookieValue(java.net.URL url, Cookie[] cookies) Returns a Cookie or Cookie2 header value for an array of cookies being sent to a URL. |
boolean |
equals(java.lang.Object obj) Compares two Cookies. |
boolean |
getExpired() Returns whether the cookie has expired. |
static Cookie[] |
parseCookies(java.net.URL url, java.lang.String setCookieValue) Creates an array of cookies from a Set-Cookie or Set-Cookie2 header value. |
static boolean |
sameCookie(Cookie cookie1, Cookie cookie2) Compares two Cookies. |
boolean |
sendToURL(java.net.URL url) Returns whether the cookie should be sent to the URL. |
java.lang.String |
toString() Returns the cookie as a string appropriate for a Cookie or Cookie2 header. |
static Cookie[] |
updateCookies(Cookie[] cookies1, Cookie[] cookies2) Updates an array of cookies with another array of cookies. |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public Cookie(java.net.URL url, java.lang.String cookieString)
url
- The URL from which the cookie came.cookieString
- The cookie string.Method Detail |
public static java.lang.String buildCookieValue(java.net.URL url, Cookie[] cookies)
url
- The URL to which the header will be sent.cookies
- The cookies that may be sent in the header.public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
obj
- The Cookie to compare against.public boolean getExpired()
public static Cookie[] parseCookies(java.net.URL url, java.lang.String setCookieValue)
url
- The URL from which the header came.setCookieValue
- The value from the Set-Cookie or Set-Cookie2 header.public static boolean sameCookie(Cookie cookie1, Cookie cookie2)
cookie1
- A Cookie.cookie2
- A Cookie.public boolean sendToURL(java.net.URL url)
public java.lang.String toString()
toString
in class java.lang.Object
public static Cookie[] updateCookies(Cookie[] cookies1, Cookie[] cookies2)
cookies1
array can be updated. The returned array will be a reference to a new array if cookies were added to it.cookies1
- The array of Cookies being updated.cookies2
- The array of Cookies by which to update.cookies1
.
|
Oracle® XML Java API Reference 10g Release 1 (10.1) B12024-02 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |