nsICookie2.idl 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364
  1. /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. #include "nsICookie.idl"
  6. /**
  7. * Main cookie object interface for use by consumers:
  8. * extends nsICookie, a frozen interface for external
  9. * access of cookie objects
  10. */
  11. [scriptable, uuid(05c420e5-03d0-4c7b-a605-df7ebe5ca326)]
  12. interface nsICookie2 : nsICookie
  13. {
  14. /**
  15. * the host (possibly fully qualified) of the cookie,
  16. * without a leading dot to represent if it is a
  17. * domain cookie.
  18. */
  19. readonly attribute AUTF8String rawHost;
  20. /**
  21. * true if the cookie is a session cookie.
  22. * note that expiry time will also be honored
  23. * for session cookies (see below); thus, whichever is
  24. * the more restrictive of the two will take effect.
  25. */
  26. readonly attribute boolean isSession;
  27. /**
  28. * the actual expiry time of the cookie, in seconds
  29. * since midnight (00:00:00), January 1, 1970 UTC.
  30. *
  31. * this is distinct from nsICookie::expires, which
  32. * has different and obsolete semantics.
  33. */
  34. readonly attribute int64_t expiry;
  35. /**
  36. * true if the cookie is an http only cookie
  37. */
  38. readonly attribute boolean isHttpOnly;
  39. /**
  40. * the creation time of the cookie, in microseconds
  41. * since midnight (00:00:00), January 1, 1970 UTC.
  42. */
  43. readonly attribute int64_t creationTime;
  44. /**
  45. * the last time the cookie was accessed (i.e. created,
  46. * modified, or read by the server), in microseconds
  47. * since midnight (00:00:00), January 1, 1970 UTC.
  48. *
  49. * note that this time may be approximate.
  50. */
  51. readonly attribute int64_t lastAccessed;
  52. };