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

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

Issue 7064033: Virtual destructors should have virtual keyword. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 years, 7 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
« no previous file with comments | « chrome/browser/net/net_pref_observer.h ('k') | chrome/browser/net/url_request_failed_dns_job.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 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 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 #pragma once 7 #pragma once
8 8
9 #include <deque> 9 #include <deque>
10 #include <string> 10 #include <string>
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 83
84 // Appends all the captured entries to |out|. The ordering is undefined. 84 // Appends all the captured entries to |out|. The ordering is undefined.
85 virtual void AppendAllEntries(ChromeNetLog::EntryList* out) const = 0; 85 virtual void AppendAllEntries(ChromeNetLog::EntryList* out) const = 0;
86 }; 86 };
87 87
88 // This source tracker is intended for TYPE_NONE. All entries go into a 88 // This source tracker is intended for TYPE_NONE. All entries go into a
89 // circular buffer, and there is no concept of live/dead requests. 89 // circular buffer, and there is no concept of live/dead requests.
90 class GlobalSourceTracker : public SourceTrackerInterface { 90 class GlobalSourceTracker : public SourceTrackerInterface {
91 public: 91 public:
92 GlobalSourceTracker(); 92 GlobalSourceTracker();
93 ~GlobalSourceTracker(); 93 virtual ~GlobalSourceTracker();
94 94
95 // SourceTrackerInterface implementation: 95 // SourceTrackerInterface implementation:
96 virtual void OnAddEntry(const ChromeNetLog::Entry& entry); 96 virtual void OnAddEntry(const ChromeNetLog::Entry& entry);
97 virtual void Clear(); 97 virtual void Clear();
98 virtual void AppendAllEntries(ChromeNetLog::EntryList* out) const; 98 virtual void AppendAllEntries(ChromeNetLog::EntryList* out) const;
99 99
100 private: 100 private:
101 typedef std::deque<ChromeNetLog::Entry> CircularEntryList; 101 typedef std::deque<ChromeNetLog::Entry> CircularEntryList;
102 CircularEntryList entries_; 102 CircularEntryList entries_;
103 DISALLOW_COPY_AND_ASSIGN(GlobalSourceTracker); 103 DISALLOW_COPY_AND_ASSIGN(GlobalSourceTracker);
(...skipping 232 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 explicit HttpStreamJobTracker(PassiveLogCollector* parent); 336 explicit HttpStreamJobTracker(PassiveLogCollector* parent);
337 337
338 private: 338 private:
339 virtual Action DoAddEntry(const ChromeNetLog::Entry& entry, 339 virtual Action DoAddEntry(const ChromeNetLog::Entry& entry,
340 SourceInfo* out_info); 340 SourceInfo* out_info);
341 DISALLOW_COPY_AND_ASSIGN(HttpStreamJobTracker); 341 DISALLOW_COPY_AND_ASSIGN(HttpStreamJobTracker);
342 }; 342 };
343 343
344 344
345 PassiveLogCollector(); 345 PassiveLogCollector();
346 ~PassiveLogCollector(); 346 virtual ~PassiveLogCollector();
347 347
348 // ThreadSafeObserver implementation: 348 // ThreadSafeObserver implementation:
349 virtual void OnAddEntry(net::NetLog::EventType type, 349 virtual void OnAddEntry(net::NetLog::EventType type,
350 const base::TimeTicks& time, 350 const base::TimeTicks& time,
351 const net::NetLog::Source& source, 351 const net::NetLog::Source& source,
352 net::NetLog::EventPhase phase, 352 net::NetLog::EventPhase phase,
353 net::NetLog::EventParameters* params); 353 net::NetLog::EventParameters* params);
354 354
355 // Clears all of the passively logged data. 355 // Clears all of the passively logged data.
356 void Clear(); 356 void Clear();
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
388 SourceTrackerInterface* trackers_[net::NetLog::SOURCE_COUNT]; 388 SourceTrackerInterface* trackers_[net::NetLog::SOURCE_COUNT];
389 389
390 // The count of how many events have flowed through this log. Used to set the 390 // The count of how many events have flowed through this log. Used to set the
391 // "order" field on captured events. 391 // "order" field on captured events.
392 uint32 num_events_seen_; 392 uint32 num_events_seen_;
393 393
394 DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector); 394 DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector);
395 }; 395 };
396 396
397 #endif // CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_ 397 #endif // CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_
OLDNEW
« no previous file with comments | « chrome/browser/net/net_pref_observer.h ('k') | chrome/browser/net/url_request_failed_dns_job.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698