| Index: net/cookies/cookie_monster.h
|
| ===================================================================
|
| --- net/cookies/cookie_monster.h (revision 269838)
|
| +++ net/cookies/cookie_monster.h (working copy)
|
| @@ -307,6 +307,19 @@
|
| static const char* kDefaultCookieableSchemes[];
|
| static const int kDefaultCookieableSchemesCount;
|
|
|
| + // Copies all keys for the given |key| to another cookie monster |other|.
|
| + // Both |other| and |this| must be loaded for this operation to succeed.
|
| + // Furthermore, there may not be any cookies stored in |other| for |key|.
|
| + // Returns false if any of these conditions is not met.
|
| + bool CopyCookiesForKeyToOtherCookieMonster(std::string key,
|
| + CookieMonster* other);
|
| +
|
| + // Find the key (for lookup in cookies_) based on the given domain.
|
| + // See comment on keys before the CookieMap typedef.
|
| + std::string GetKey(const std::string& domain) const;
|
| +
|
| + bool loaded();
|
| +
|
| private:
|
| // For queueing the cookie monster calls.
|
| class CookieMonsterTask;
|
| @@ -455,6 +468,7 @@
|
| InitStore();
|
| } else {
|
| loaded_ = true;
|
| + ReportLoaded();
|
| }
|
| initialized_ = true;
|
| }
|
| @@ -464,6 +478,9 @@
|
| // Should only be called by InitIfNecessary().
|
| void InitStore();
|
|
|
| + // Reports to the delegate that the cookie monster was loaded.
|
| + void ReportLoaded();
|
| +
|
| // Stores cookies loaded from the backing store and invokes any deferred
|
| // calls. |beginning_time| should be the moment PersistentCookieStore::Load
|
| // was invoked and is used for reporting histogram_time_blocked_on_load_.
|
| @@ -576,10 +593,6 @@
|
| CookieItVector::iterator cookie_its_begin,
|
| CookieItVector::iterator cookie_its_end);
|
|
|
| - // Find the key (for lookup in cookies_) based on the given domain.
|
| - // See comment on keys before the CookieMap typedef.
|
| - std::string GetKey(const std::string& domain) const;
|
| -
|
| bool HasCookieableScheme(const GURL& url);
|
|
|
| // Statistics support
|
| @@ -720,6 +733,9 @@
|
| virtual void OnCookieChanged(const CanonicalCookie& cookie,
|
| bool removed,
|
| ChangeCause cause) = 0;
|
| + // Indicates that the cookie store has fully loaded.
|
| + virtual void OnLoaded() = 0;
|
| +
|
| protected:
|
| friend class base::RefCountedThreadSafe<CookieMonsterDelegate>;
|
| virtual ~CookieMonsterDelegate() {}
|
|
|