OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 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 | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef BASE_TRACE_EVENT_MEMORY_DUMP_PROVIDER_H_ | 5 #ifndef BASE_TRACE_EVENT_MEMORY_DUMP_PROVIDER_H_ |
6 #define BASE_TRACE_EVENT_MEMORY_DUMP_PROVIDER_H_ | 6 #define BASE_TRACE_EVENT_MEMORY_DUMP_PROVIDER_H_ |
7 | 7 |
8 #include "base/base_export.h" | 8 #include "base/base_export.h" |
9 #include "base/macros.h" | 9 #include "base/macros.h" |
10 #include "base/process/process_handle.h" | 10 #include "base/process/process_handle.h" |
11 #include "base/trace_event/memory_dump_request_args.h" | 11 #include "base/trace_event/process_memory_dump.h" |
Primiano Tucci (use gerrit)
2016/06/02 20:24:04
hmm I wonder if this can end up pulling too many h
ssid
2016/06/03 01:59:46
Done.
| |
12 | 12 |
13 namespace base { | 13 namespace base { |
14 namespace trace_event { | 14 namespace trace_event { |
15 | 15 |
16 class ProcessMemoryDump; | |
17 | |
18 // Args passed to OnMemoryDump(). This is to avoid rewriting all the subclasses | |
19 // in the codebase when extending the MemoryDumpProvider API. | |
20 struct MemoryDumpArgs { | |
21 MemoryDumpLevelOfDetail level_of_detail; | |
22 }; | |
23 | |
24 // The contract interface that memory dump providers must implement. | 16 // The contract interface that memory dump providers must implement. |
25 class BASE_EXPORT MemoryDumpProvider { | 17 class BASE_EXPORT MemoryDumpProvider { |
26 public: | 18 public: |
27 // Optional arguments for MemoryDumpManager::RegisterDumpProvider(). | 19 // Optional arguments for MemoryDumpManager::RegisterDumpProvider(). |
28 struct Options { | 20 struct Options { |
29 Options() | 21 Options() |
30 : target_pid(kNullProcessId), | 22 : target_pid(kNullProcessId), |
31 dumps_on_single_thread_task_runner(false) {} | 23 dumps_on_single_thread_task_runner(false) {} |
32 | 24 |
33 // If the dump provider generates dumps on behalf of another process, | 25 // If the dump provider generates dumps on behalf of another process, |
(...skipping 27 matching lines...) Expand all Loading... | |
61 protected: | 53 protected: |
62 MemoryDumpProvider() {} | 54 MemoryDumpProvider() {} |
63 | 55 |
64 DISALLOW_COPY_AND_ASSIGN(MemoryDumpProvider); | 56 DISALLOW_COPY_AND_ASSIGN(MemoryDumpProvider); |
65 }; | 57 }; |
66 | 58 |
67 } // namespace trace_event | 59 } // namespace trace_event |
68 } // namespace base | 60 } // namespace base |
69 | 61 |
70 #endif // BASE_TRACE_EVENT_MEMORY_DUMP_PROVIDER_H_ | 62 #endif // BASE_TRACE_EVENT_MEMORY_DUMP_PROVIDER_H_ |
OLD | NEW |