public interface CookieStore
| Modifier and Type | Method and Description |
|---|---|
void |
add(URI uri,
HttpCookie cookie)
Saves a HTTP cookie to this store.
|
List<HttpCookie> |
get(URI uri)
Retrieves cookies that match the specified URI.
|
List<HttpCookie> |
getCookies()
Get all cookies in cookie store which are not expired.
|
List<URI> |
getURIs()
Get a set of URIs, which is composed of associated URI with all the
cookies in the store.
|
boolean |
remove(URI uri,
HttpCookie cookie)
Remove the specified cookie from the store.
|
boolean |
removeAll()
Clear this cookie store.
|
void add(URI uri, HttpCookie cookie)
uri - the uri associated with the specified cookie. A null value
indicates the cookie is not associated with a URIcookie - the cookie to be storedList<HttpCookie> get(URI uri)
uri - the uri this cookie associated with. If null, this cookie will
not be associated with an URINullPointerException - if uri is nullList<HttpCookie> getCookies()
List<URI> getURIs()
boolean remove(URI uri, HttpCookie cookie)
uri - the uri associated with the specified cookie. If the cookie is
not associated with an URI when added, uri should be null;
otherwise the uri should be non-null.cookie - the cookie to be removedboolean removeAll()