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

Side by Side Diff: content/browser/profiler_controller_impl.h

Issue 8588023: Collect profiler stats from browser child processes. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years 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 | Annotate | Revision Log
Property Changes:
Added: svn:executable
+ *
OLDNEW
(Empty)
1 // Copyright (c) 2011 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 CONTENT_BROWSER_PROFILER_CONTROLLER_IMPL_H_
6 #define CONTENT_BROWSER_PROFILER_CONTROLLER_IMPL_H_
7
8 #include "base/memory/singleton.h"
9 #include "content/common/content_export.h"
10 #include "content/public/browser/profiler_controller.h"
11
12 namespace content {
13
14 // ProfilerController's implementation.
15 class CONTENT_EXPORT ProfilerControllerImpl : public ProfilerController {
16 public:
17 static ProfilerControllerImpl* GetInstance();
18
19 // Normally instantiated when the child process is launched. Only one instance
20 // should be created per process.
21 ProfilerControllerImpl();
22 virtual ~ProfilerControllerImpl();
23
24 // ----------------------------------
jam 2011/11/30 00:22:25 nit: why add the "// -----------------------------
ramant (doing other things) 2011/11/30 19:37:21 Done.
25 // ProfilerController implementation:
26 // ----------------------------------
27
28 virtual void Register(ProfilerSubscriber* subscriber) OVERRIDE;
29
30 virtual void Unregister(ProfilerSubscriber* subscriber) OVERRIDE;
31
32 // Send number of pending processes to subscriber_.
33 // This is called on UI thread.
34 void OnPendingProcesses(int sequence_number, int pending_processes);
35
36 // Send profiler_data back to subscriber_. subscriber_ assumes the ownership
37 // of profiler_data. This is called on UI thread.
38 void OnProfilerDataCollected(int sequence_number,
39 base::DictionaryValue* profiler_data);
40
41 private:
42 friend struct DefaultSingletonTraits<ProfilerControllerImpl>;
43
44 ProfilerSubscriber* subscriber_;
45
46 DISALLOW_COPY_AND_ASSIGN(ProfilerControllerImpl);
47 };
48
49 } // namespace content
50
51 #endif // CONTENT_BROWSER_PROFILER_CONTROLLER_IMPL_H_
52
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698