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

Side by Side Diff: content/public/browser/devtools_target_list.h

Issue 12319114: Extract debugger target enumeration into a separate class (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@debugger
Patch Set: Fixed thumbnail url generation, added a test Created 7 years, 9 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
(Empty)
1 // Copyright (c) 2012 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_PUBLIC_BROWSER_DEVTOOLS_TARGET_LIST_H_
6 #define CONTENT_PUBLIC_BROWSER_DEVTOOLS_TARGET_LIST_H_
7
8 #include <map>
9 #include <string>
10
11 #include "base/memory/ref_counted.h"
12 #include "content/common/content_export.h"
13
14 namespace content {
15
16 class DevToolsAgentHost;
17
18 class CONTENT_EXPORT DevToolsTargetList {
19 public:
20 static DevToolsTargetList* GetInstance();
21
22 typedef std::map<std::string, scoped_refptr<DevToolsAgentHost> > AgentsMap;
23
24 AgentsMap::iterator begin() { return agents_map_.begin(); }
pfeldman 2013/03/04 11:43:01 I still prefer vector::iterator as the return type
Vladislav Kaznacheev 2013/03/04 14:30:03 Discussed offline, agreed to keep as is. On 2013/0
25
26 AgentsMap::iterator end() { return agents_map_.end(); }
27
28 void Refresh();
29
30 void Register(DevToolsAgentHost* agent_host);
31
32 DevToolsAgentHost* Lookup(const std::string& id);
33
34 private:
35 AgentsMap agents_map_;
36
37 void GarbageCollect();
38 };
39
40 } // namespace content
41
42 #endif // CONTENT_PUBLIC_BROWSER_DEVTOOLS_TARGET_LIST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698