nsICookieService should provide getCookie, a method that returns a nsICookie

RESOLVED FIXED

Status

()

Core
Networking: Cookies
--
enhancement
RESOLVED FIXED
13 years ago
2 years ago

People

(Reporter: Jason Barnabe (np), Unassigned)

Tracking

Trunk
All
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Reporter)

Description

13 years ago
nsICookieService provides, among other things, getCookieString and getCookieStringFromHttp. They provide a cookie string that has to be parsed to be useful. This interface would be much more useful if it had methods that returned nsICookies.

Comment 1

13 years ago
have you looked at nsICookieManager/nsICookieManager2? please elaborate on why you think this is a good idea.
(Reporter)

Comment 2

13 years ago
nsICookieManager makes you enumerate through every cookie to find what you want. nsICookieManager2 has nothing comparable.

It's a good idea because it would make that interface actually useful. If I want to read a cookie's value, right now I either have to enumerate through every cookie with nsICookieManager or get the cookie string and then implement cookie parsing logic. There's currently no interface that I know of to go from a cookie string to a nsICookie.

(It doesn't matter to me whether it goes in nsICookieManager or nsICookieService.)

Comment 3

13 years ago
What about nsICookieServiceInternal::getCookieValue?

Comment 4

13 years ago
Nevermind.  That API doesn't seem to do what you want either.

Updated

12 years ago
Assignee: darin → nobody

Comment 5

11 years ago
-> me, seems like a good idea.
Assignee: nobody → dwitte

Comment 6

10 years ago
this will be fixed by the patch in bug 423132.
Depends on: 423132

Comment 7

8 years ago
Reassigning to nobody. If anyone wants to work on this, feel free!
Assignee: dwitte → nobody
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.