Index: components/metrics/leak_detector/leak_detector.h |
diff --git a/components/metrics/leak_detector/leak_detector.h b/components/metrics/leak_detector/leak_detector.h |
index fb624a281dd2eb59bdd951eb1a46634a5d4e73d7..0faf821c5e78f21f198dbc3a30af56578b4d76ca 100644 |
--- a/components/metrics/leak_detector/leak_detector.h |
+++ b/components/metrics/leak_detector/leak_detector.h |
@@ -20,7 +20,6 @@ |
#include "base/synchronization/lock.h" |
#include "base/task_runner.h" |
#include "base/threading/thread_checker.h" |
-#include "components/metrics/proto/memory_leak_report.pb.h" |
namespace base { |
template <typename T> |
@@ -29,6 +28,9 @@ struct DefaultLazyInstanceTraits; |
namespace metrics { |
+class MemoryLeakReportProto; |
+class MemoryLeakReportProto_Params; |
+ |
namespace leak_detector { |
class LeakDetectorImpl; |
} |
@@ -66,13 +68,16 @@ class LeakDetector { |
// Initializes leak detector. Args: |
// - |params| is a set of parameters used by the leak detector. See definition |
- // of MemoryLeakReportProto::Params for info about individual parameters. |
+ // of MemoryLeakReportProto_Params for info about individual parameters. |
// - |task_runner| is a TaskRunner to which NotifyObservers() should be |
// posted, if it is initally called from a different thread than the one on |
// which |task_runner| runs. |
- void Init(const MemoryLeakReportProto::Params& params, |
+ void Init(const MemoryLeakReportProto_Params& params, |
scoped_refptr<base::TaskRunner> task_runner); |
+ // Initializes static elements within this class, such as TLS. |
+ static void StaticInit(); |
Primiano Tucci (use gerrit)
2016/06/01 21:26:30
I'd call it InitTLSSlot() and not static init.
Tec
Simon Que
2016/06/02 17:55:17
Done.
|
+ |
// Add |observer| to the list of stored Observers, i.e. |observers_|, to which |
// the leak detector will report leaks. |
void AddObserver(Observer* observer); |