TOC PREV NEXT INDEX

Embedding Gecko API


nsICookie


This interface provides a means of accessing information stored in the HTTP or JavaScript cookie object. It is scriptable.

Attributes and Contstants
readonly attribute ACString nsICookie::name

Gets the name of the cookie.

readonly attribute ACString nsICookie::value

Gets the cookie value.

readonly attribute boolean nsICookie::isDomain

Gets TRUE if the cookie is a domain cookie, FALSE otherwise.

readonly attribute AUTF8String nsICookie::host

Gets the host, possibly fully qualified, of the cookie.

readonly attribute AUTF8String nsICookie::path

Gets the path pertaining to the cookie.

readonly attribute boolean nsICookie::isSecure

Gets TRUE if the cookie was transmitted over SSL, FALSE otherwise.

readonly attribute PRUint64 nsICookie::expires

Gets the expiration time (local timezone) expressed as the number of seconds since Jan 1, 1970.

readonly attribute nsCookieStatus nsICookie::status

Gets the P3P status of cookie. Values returned as nsCookieStatus constants below.

const nsCookieStatus nsICookie::STATUS_UNKNOWN=0

The cookie was collected in a previous session and this info is no longer available.

const nsCookieStatus nsICookie::STATUS_ACCEPTED=1

The cookie was accepted as is.

const nsCookieStatus nsICookie::STATUS_DOWNGRADED=2

The cookie was accepted but downgraded to a session cookie.

const nsCookieStatus nsICookie::STATUS_FLAGGED=3

The cookie was accepted with a warning being issued to the user.

const nsCookieStatus nsICookie::STATUS_REJECTED=4

.The cookie was not accepted.

readonly attribute nsCookiePolicy nsICookie::policy

Gets the compact cookie policy. Values returned as nsCookiePolicy constants below.

const nsCookiePolicy nsICookie::POLICY_UNKNOWN=0

The cookie was collected in a previous session and this info is no longer available.

const nsCookiePolicy nsICookie::POLICY_NONE=1

The site did not send a compact policy along with the cookie.

const nsCookiePolicy nsICookie::POLICY_NO_CONSENT=2

The site collects identfiable information without user involvement.

const nsCookiePolicy nsICookie:: POLICY_IMPLICIT_CONSENT=3

The site collects identifiable information unless user opts out.

const nsCookiePolicy nsICookie::POLICY_EXPLICIT_CONSENT=4

The site does not collect identifiable information unless user opts in.

const nsCookiePolicy nsICookie::POLICY_NO_II=5

The site does not collect identifiable information.


Written by:Ellen Evans | Comments, questions, complaints? Bug 143387
TOC PREV NEXT INDEX