Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(272)

Side by Side Diff: components/tracing/child_memory_dump_manager_delegate_impl.cc

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #include "components/tracing/child_memory_dump_manager_delegate_impl.h" 5 #include "components/tracing/child_memory_dump_manager_delegate_impl.h"
6 6
7 #include "base/single_thread_task_runner.h" 7 #include "base/single_thread_task_runner.h"
8 #include "components/tracing/child_trace_message_filter.h" 8 #include "components/tracing/child_trace_message_filter.h"
9 9
10 namespace tracing { 10 namespace tracing {
11 11
12 // static 12 // static
13 ChildMemoryDumpManagerDelegateImpl* 13 ChildMemoryDumpManagerDelegateImpl*
14 ChildMemoryDumpManagerDelegateImpl::GetInstance() { 14 ChildMemoryDumpManagerDelegateImpl::GetInstance() {
15 return Singleton< 15 return base::Singleton<
16 ChildMemoryDumpManagerDelegateImpl, 16 ChildMemoryDumpManagerDelegateImpl,
17 LeakySingletonTraits<ChildMemoryDumpManagerDelegateImpl>>::get(); 17 base::LeakySingletonTraits<ChildMemoryDumpManagerDelegateImpl>>::get();
18 } 18 }
19 19
20 ChildMemoryDumpManagerDelegateImpl::ChildMemoryDumpManagerDelegateImpl() 20 ChildMemoryDumpManagerDelegateImpl::ChildMemoryDumpManagerDelegateImpl()
21 : ctmf_(nullptr), 21 : ctmf_(nullptr),
22 tracing_process_id_( 22 tracing_process_id_(
23 base::trace_event::MemoryDumpManager::kInvalidTracingProcessId) { 23 base::trace_event::MemoryDumpManager::kInvalidTracingProcessId) {
24 base::trace_event::MemoryDumpManager::GetInstance()->SetDelegate(this); 24 base::trace_event::MemoryDumpManager::GetInstance()->SetDelegate(this);
25 } 25 }
26 26
27 ChildMemoryDumpManagerDelegateImpl::~ChildMemoryDumpManagerDelegateImpl() { 27 ChildMemoryDumpManagerDelegateImpl::~ChildMemoryDumpManagerDelegateImpl() {
(...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 72
73 bool ChildMemoryDumpManagerDelegateImpl::IsCoordinatorProcess() const { 73 bool ChildMemoryDumpManagerDelegateImpl::IsCoordinatorProcess() const {
74 return false; 74 return false;
75 } 75 }
76 76
77 uint64 ChildMemoryDumpManagerDelegateImpl::GetTracingProcessId() const { 77 uint64 ChildMemoryDumpManagerDelegateImpl::GetTracingProcessId() const {
78 return tracing_process_id_; 78 return tracing_process_id_;
79 } 79 }
80 80
81 } // namespace tracing 81 } // namespace tracing
OLDNEW
« no previous file with comments | « components/tracing/child_memory_dump_manager_delegate_impl.h ('k') | components/tracing/trace_config_file.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698