Loading netwerk/base/public/nsICachingChannel.idl +7 −0 Original line number Diff line number Diff line Loading @@ -64,6 +64,13 @@ interface nsICachingChannel : nsICacheInfoChannel */ attribute nsISupports cacheKey; /** * Set/get the cache domain... uniquely identifies the data in the cache * for this channel. Holding a reference to this key does NOT prevent * the cached data from being removed. */ attribute AUTF8String cacheDomain; /************************************************************************** * Caching channel specific load flags: */ Loading netwerk/protocol/http/nsHttpChannel.cpp +22 −0 Original line number Diff line number Diff line Loading @@ -2726,6 +2726,12 @@ nsHttpChannel::AssembleCacheKey(const char *spec, uint32_t postID, cacheKey.Append(buf); } if (strlen(mCacheDomain.get()) > 0) { cacheKey.AppendLiteral("domain="); cacheKey.Append(mCacheDomain.get()); cacheKey.AppendLiteral("&"); } if (!cacheKey.IsEmpty()) { cacheKey.AppendLiteral("uri="); } Loading Loading @@ -5270,6 +5276,22 @@ nsHttpChannel::SetCacheTokenCachedCharset(const nsACString &aCharset) // nsHttpChannel::nsICachingChannel //----------------------------------------------------------------------------- NS_IMETHODIMP nsHttpChannel::GetCacheDomain(nsACString &value) { value = mCacheDomain; return NS_OK; } NS_IMETHODIMP nsHttpChannel::SetCacheDomain(const nsACString &value) { mCacheDomain = value; return NS_OK; } NS_IMETHODIMP nsHttpChannel::GetCacheToken(nsISupports **token) { Loading netwerk/protocol/http/nsHttpChannel.h +1 −0 Original line number Diff line number Diff line Loading @@ -313,6 +313,7 @@ private: nsCacheAccessMode mOfflineCacheAccess; uint32_t mOfflineCacheLastModifiedTime; nsCOMPtr<nsIApplicationCache> mApplicationCacheForWrite; nsCString mCacheDomain; // auth specific data nsCOMPtr<nsIHttpChannelAuthProvider> mAuthProvider; Loading Loading
netwerk/base/public/nsICachingChannel.idl +7 −0 Original line number Diff line number Diff line Loading @@ -64,6 +64,13 @@ interface nsICachingChannel : nsICacheInfoChannel */ attribute nsISupports cacheKey; /** * Set/get the cache domain... uniquely identifies the data in the cache * for this channel. Holding a reference to this key does NOT prevent * the cached data from being removed. */ attribute AUTF8String cacheDomain; /************************************************************************** * Caching channel specific load flags: */ Loading
netwerk/protocol/http/nsHttpChannel.cpp +22 −0 Original line number Diff line number Diff line Loading @@ -2726,6 +2726,12 @@ nsHttpChannel::AssembleCacheKey(const char *spec, uint32_t postID, cacheKey.Append(buf); } if (strlen(mCacheDomain.get()) > 0) { cacheKey.AppendLiteral("domain="); cacheKey.Append(mCacheDomain.get()); cacheKey.AppendLiteral("&"); } if (!cacheKey.IsEmpty()) { cacheKey.AppendLiteral("uri="); } Loading Loading @@ -5270,6 +5276,22 @@ nsHttpChannel::SetCacheTokenCachedCharset(const nsACString &aCharset) // nsHttpChannel::nsICachingChannel //----------------------------------------------------------------------------- NS_IMETHODIMP nsHttpChannel::GetCacheDomain(nsACString &value) { value = mCacheDomain; return NS_OK; } NS_IMETHODIMP nsHttpChannel::SetCacheDomain(const nsACString &value) { mCacheDomain = value; return NS_OK; } NS_IMETHODIMP nsHttpChannel::GetCacheToken(nsISupports **token) { Loading
netwerk/protocol/http/nsHttpChannel.h +1 −0 Original line number Diff line number Diff line Loading @@ -313,6 +313,7 @@ private: nsCacheAccessMode mOfflineCacheAccess; uint32_t mOfflineCacheLastModifiedTime; nsCOMPtr<nsIApplicationCache> mApplicationCacheForWrite; nsCString mCacheDomain; // auth specific data nsCOMPtr<nsIHttpChannelAuthProvider> mAuthProvider; Loading