public class CookieJar extends Object
| Constructor and Description |
|---|
CookieJar(UploadPolicy uploadPolicy)
The creator for this class.
|
| Modifier and Type | Method and Description |
|---|---|
String |
buildCookieHeader(URL url)
Builds a RFC 2109 compliant client cookie header for the specified URL.
|
void |
parseCookieHeader(String s)
Parses a "Set-Cookie" header and creates/updates/deletes cookies
according to the parsed values.
|
void |
setDomain(String domain)
Sets the domain for this cookie jar.
|
public CookieJar(UploadPolicy uploadPolicy)
uploadPolicy - The current upload policypublic void setDomain(String domain)
domain - The domain of this instancepublic String buildCookieHeader(URL url)
url - The URL for which the cookie header is to be used.public void parseCookieHeader(String s)
s - The plain value of the "Set-Cookie" HTTP header. e.g.: without
the "Set-Cookie: " prefix.Copyright © 2015. All rights reserved.