Index: content/browser/dom_storage/dom_storage_area.h |
diff --git a/content/browser/dom_storage/dom_storage_area.h b/content/browser/dom_storage/dom_storage_area.h |
index 9fc646be19bae8f38225e9204c780fb8ab094188..06c06e84ab0580d58bf3bd375b5afeb971f5c339 100644 |
--- a/content/browser/dom_storage/dom_storage_area.h |
+++ b/content/browser/dom_storage/dom_storage_area.h |
@@ -18,6 +18,7 @@ |
#include "base/strings/nullable_string16.h" |
#include "base/strings/string16.h" |
#include "content/common/content_export.h" |
+#include "content/common/dom_storage/dom_storage_map.h" |
#include "content/common/dom_storage/dom_storage_types.h" |
#include "url/gurl.h" |
@@ -30,7 +31,6 @@ class ProcessMemoryDump; |
namespace content { |
class DOMStorageDatabaseAdapter; |
-class DOMStorageMap; |
class DOMStorageTaskRunner; |
class SessionStorageDatabase; |
@@ -65,6 +65,7 @@ class CONTENT_EXPORT DOMStorageArea |
const GURL& origin() const { return origin_; } |
int64_t namespace_id() const { return namespace_id_; } |
+ size_t map_usage_in_bytes() const { return map_ ? map_->bytes_used() : 0; } |
// Writes a copy of the current set of values in the area to the |map|. |
void ExtractValues(DOMStorageValuesMap* map); |
@@ -116,6 +117,7 @@ class CONTENT_EXPORT DOMStorageArea |
FRIEND_TEST_ALL_PREFIXES(DOMStorageAreaTest, PurgeMemory); |
FRIEND_TEST_ALL_PREFIXES(DOMStorageAreaTest, RateLimiter); |
FRIEND_TEST_ALL_PREFIXES(DOMStorageContextImplTest, PersistentIds); |
+ FRIEND_TEST_ALL_PREFIXES(DOMStorageContextImplTest, PurgeMemory); |
friend class base::RefCountedThreadSafe<DOMStorageArea>; |
// Used to rate limit commits. |