Index: base/metrics/persistent_memory_allocator.h |
diff --git a/base/metrics/persistent_memory_allocator.h b/base/metrics/persistent_memory_allocator.h |
index 4c0db5264a8f810721653d130c6428437ef5f9aa..56edd2ca24e0131d633b7aea805bd80e3681cb66 100644 |
--- a/base/metrics/persistent_memory_allocator.h |
+++ b/base/metrics/persistent_memory_allocator.h |
@@ -12,6 +12,7 @@ |
#include "base/atomicops.h" |
#include "base/base_export.h" |
+#include "base/files/file_path.h" |
#include "base/gtest_prod_util.h" |
#include "base/macros.h" |
#include "base/strings/string_piece.h" |
@@ -126,6 +127,10 @@ class BASE_EXPORT PersistentMemoryAllocator { |
kTypeIdAny = 0 // Match any type-id inside GetAsObject(). |
}; |
+ // This is the standard file extension (suitable for being passed to the |
+ // AddExtension() method of base::FilePath) for dumps of persistent memory. |
+ static const base::FilePath::CharType kFileExtension[]; |
+ |
// The allocator operates on any arbitrary block of memory. Creation and |
// persisting or sharing of that block with another process is the |
// responsibility of the caller. The allocator needs to know only the |
@@ -191,6 +196,7 @@ class BASE_EXPORT PersistentMemoryAllocator { |
// not guarantee consistency. Use with care. Do not write. |
const void* data() const { return const_cast<const char*>(mem_base_); } |
size_t length() const { return mem_size_; } |
+ size_t size() const { return mem_size_; } |
size_t used() const; |
// Get an object referenced by a |ref|. For safety reasons, the |type_id| |