OLD | NEW |
(Empty) | |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef BASE_TRACE_EVENT_PROCESS_MEMORY_TOTALS_DUMP_PROVIDER_H_ |
| 6 #define BASE_TRACE_EVENT_PROCESS_MEMORY_TOTALS_DUMP_PROVIDER_H_ |
| 7 |
| 8 #include "base/memory/scoped_ptr.h" |
| 9 #include "base/memory/singleton.h" |
| 10 #include "base/trace_event/memory_dump_provider.h" |
| 11 |
| 12 namespace base { |
| 13 |
| 14 class ProcessMetrics; |
| 15 |
| 16 namespace trace_event { |
| 17 |
| 18 // Dump provider which collects process-wide memory stats. |
| 19 class BASE_EXPORT ProcessMemoryTotalsDumpProvider : public MemoryDumpProvider { |
| 20 public: |
| 21 static ProcessMemoryTotalsDumpProvider* GetInstance(); |
| 22 |
| 23 // MemoryDumpProvider implementation. |
| 24 void DumpInto(ProcessMemoryDump* pmd) override; |
| 25 |
| 26 private: |
| 27 friend struct DefaultSingletonTraits<ProcessMemoryTotalsDumpProvider>; |
| 28 |
| 29 ProcessMemoryTotalsDumpProvider(); |
| 30 ~ProcessMemoryTotalsDumpProvider() override; |
| 31 |
| 32 scoped_ptr<ProcessMetrics> process_metrics_; |
| 33 |
| 34 DISALLOW_COPY_AND_ASSIGN(ProcessMemoryTotalsDumpProvider); |
| 35 }; |
| 36 |
| 37 } // namespace trace_event |
| 38 } // namespace base |
| 39 |
| 40 #endif // BASE_TRACE_EVENT_PROCESS_MEMORY_TOTALS_DUMP_PROVIDER_H_ |
OLD | NEW |