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

Side by Side Diff: chrome/browser/net/passive_log_collector.h

Issue 1052002: Move over another legacy "LoadLog-style" event generator to routing its messa... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Address willchan's comments Created 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_ 5 #ifndef CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_
6 #define CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_ 6 #define CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/hash_tables.h" 10 #include "base/hash_tables.h"
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
103 // Searches through |connect_job_tracker_| for information on the 103 // Searches through |connect_job_tracker_| for information on the
104 // ConnectJob specified in |entry|, and appends it to |live_entry|. 104 // ConnectJob specified in |entry|, and appends it to |live_entry|.
105 void AddConnectJobInfo(const net::NetLog::Entry& entry, 105 void AddConnectJobInfo(const net::NetLog::Entry& entry,
106 RequestInfo* live_entry); 106 RequestInfo* live_entry);
107 107
108 ConnectJobTracker* connect_job_tracker_; 108 ConnectJobTracker* connect_job_tracker_;
109 109
110 DISALLOW_COPY_AND_ASSIGN(RequestTracker); 110 DISALLOW_COPY_AND_ASSIGN(RequestTracker);
111 }; 111 };
112 112
113 // Tracks the log entries for the last seen SOURCE_INIT_PROXY_RESOLVER.
114 class InitProxyResolverTracker {
115 public:
116 InitProxyResolverTracker();
117
118 void OnAddEntry(const net::NetLog::Entry& entry);
119
120 const std::vector<net::NetLog::Entry>& entries() const {
121 return entries_;
122 }
123
124 private:
125 std::vector<net::NetLog::Entry> entries_;
126 DISALLOW_COPY_AND_ASSIGN(InitProxyResolverTracker);
127 };
128
113 PassiveLogCollector(); 129 PassiveLogCollector();
114 ~PassiveLogCollector(); 130 ~PassiveLogCollector();
115 131
116 // Observer implementation: 132 // Observer implementation:
117 virtual void OnAddEntry(const net::NetLog::Entry& entry); 133 virtual void OnAddEntry(const net::NetLog::Entry& entry);
118 134
119 // Clears all of the passively logged data. 135 // Clears all of the passively logged data.
120 void Clear(); 136 void Clear();
121 137
122 RequestTracker* url_request_tracker() { 138 RequestTracker* url_request_tracker() {
123 return &url_request_tracker_; 139 return &url_request_tracker_;
124 } 140 }
125 141
126 RequestTracker* socket_stream_tracker() { 142 RequestTracker* socket_stream_tracker() {
127 return &socket_stream_tracker_; 143 return &socket_stream_tracker_;
128 } 144 }
129 145
146 InitProxyResolverTracker* init_proxy_resolver_tracker() {
147 return &init_proxy_resolver_tracker_;
148 }
149
130 private: 150 private:
131 ConnectJobTracker connect_job_tracker_; 151 ConnectJobTracker connect_job_tracker_;
132 RequestTracker url_request_tracker_; 152 RequestTracker url_request_tracker_;
133 RequestTracker socket_stream_tracker_; 153 RequestTracker socket_stream_tracker_;
154 InitProxyResolverTracker init_proxy_resolver_tracker_;
134 155
135 DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector); 156 DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector);
136 }; 157 };
137 158
138 #endif // CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_ 159 #endif // CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_
OLDNEW
« no previous file with comments | « chrome/browser/net/chrome_url_request_context.cc ('k') | chrome/browser/net/passive_log_collector.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698