CookieStore

A CookieStore object represents a storage for cookie. Can store and retrieve cookies.

<p>{@link CookieManager} will call {@code CookieStore.add} to save cookies for every incoming HTTP response, and call {@code CookieStore.get} to retrieve cookie for every outgoing HTTP request. A CookieStore is responsible for removing HttpCookie instances which have expired.

@author Edward Wang

Members

Aliases

clear
alias clear = removeAll
Undocumented in source.

Functions

add
void add(HttpURI uri, HttpCookie cookie)

Adds one HTTP cookie to the store. This is called for every incoming HTTP response.

clearExpired
bool clearExpired()

Removes all of {@link Cookie}s in this store that have expired by the specified SysTime.

get
HttpCookie[] get(string uri)

Retrieve cookies associated with given URI, or whose domain matches the given URI. Only cookies that have not expired are returned. This is called for every outgoing HTTP request.

getCookies
HttpCookie[] getCookies()

Get all not-expired cookies in cookie store.

getURIs
string[] getURIs()

Get all URIs which identify the cookies in this cookie store.

remove
bool remove(string uri, HttpCookie cookie)

Remove a cookie from store.

removeAll
bool removeAll()

Remove all cookies in this cookie store.

Meta