Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 423 | 423 |
| 424 HttpPipelinedConnectionTracker(); | 424 HttpPipelinedConnectionTracker(); |
| 425 | 425 |
| 426 private: | 426 private: |
| 427 virtual Action DoAddEntry(const ChromeNetLog::Entry& entry, | 427 virtual Action DoAddEntry(const ChromeNetLog::Entry& entry, |
| 428 SourceInfo* out_info) OVERRIDE; | 428 SourceInfo* out_info) OVERRIDE; |
| 429 | 429 |
| 430 DISALLOW_COPY_AND_ASSIGN(HttpPipelinedConnectionTracker); | 430 DISALLOW_COPY_AND_ASSIGN(HttpPipelinedConnectionTracker); |
| 431 }; | 431 }; |
| 432 | 432 |
| 433 | |
|
mmenke
2012/01/31 18:28:43
nit: Remove extra linebreak.
ahendrickson
2012/01/31 20:12:41
Done.
| |
| 434 // Tracks the log entries for the last seen SOURCE_FILESTREAM. | |
| 435 class FileStreamTracker : public SourceTracker { | |
| 436 public: | |
| 437 static const size_t kMaxNumSources; | |
| 438 static const size_t kMaxGraveyardSize; | |
| 439 | |
| 440 FileStreamTracker(); | |
| 441 | |
| 442 private: | |
| 443 virtual Action DoAddEntry(const ChromeNetLog::Entry& entry, | |
| 444 SourceInfo* out_info) OVERRIDE; | |
| 445 | |
| 446 DISALLOW_COPY_AND_ASSIGN(FileStreamTracker); | |
| 447 }; | |
| 448 | |
| 433 PassiveLogCollector(); | 449 PassiveLogCollector(); |
| 434 virtual ~PassiveLogCollector(); | 450 virtual ~PassiveLogCollector(); |
| 435 | 451 |
| 436 // ThreadSafeObserver implementation: | 452 // ThreadSafeObserver implementation: |
| 437 virtual void OnAddEntry(net::NetLog::EventType type, | 453 virtual void OnAddEntry(net::NetLog::EventType type, |
| 438 const base::TimeTicks& time, | 454 const base::TimeTicks& time, |
| 439 const net::NetLog::Source& source, | 455 const net::NetLog::Source& source, |
| 440 net::NetLog::EventPhase phase, | 456 net::NetLog::EventPhase phase, |
| 441 net::NetLog::EventParameters* params) OVERRIDE; | 457 net::NetLog::EventParameters* params) OVERRIDE; |
| 442 | 458 |
| (...skipping 25 matching lines...) Expand all Loading... | |
| 468 DNSJobTracker dns_job_tracker_; | 484 DNSJobTracker dns_job_tracker_; |
| 469 DiskCacheEntryTracker disk_cache_entry_tracker_; | 485 DiskCacheEntryTracker disk_cache_entry_tracker_; |
| 470 MemCacheEntryTracker mem_cache_entry_tracker_; | 486 MemCacheEntryTracker mem_cache_entry_tracker_; |
| 471 HttpStreamJobTracker http_stream_job_tracker_; | 487 HttpStreamJobTracker http_stream_job_tracker_; |
| 472 ExponentialBackoffThrottlingTracker exponential_backoff_throttling_tracker_; | 488 ExponentialBackoffThrottlingTracker exponential_backoff_throttling_tracker_; |
| 473 DnsTransactionTracker dns_transaction_tracker_; | 489 DnsTransactionTracker dns_transaction_tracker_; |
| 474 AsyncHostResolverRequestTracker async_host_resolver_request_tracker_; | 490 AsyncHostResolverRequestTracker async_host_resolver_request_tracker_; |
| 475 UDPSocketTracker udp_socket_tracker_; | 491 UDPSocketTracker udp_socket_tracker_; |
| 476 CertVerifierJobTracker cert_verifier_job_tracker_; | 492 CertVerifierJobTracker cert_verifier_job_tracker_; |
| 477 HttpPipelinedConnectionTracker http_pipelined_connection_tracker_; | 493 HttpPipelinedConnectionTracker http_pipelined_connection_tracker_; |
| 494 FileStreamTracker file_stream_tracker_; | |
| 478 | 495 |
| 479 // This array maps each NetLog::SourceType to one of the tracker instances | 496 // This array maps each NetLog::SourceType to one of the tracker instances |
| 480 // defined above. Use of this array avoid duplicating the list of trackers | 497 // defined above. Use of this array avoid duplicating the list of trackers |
| 481 // elsewhere. | 498 // elsewhere. |
| 482 SourceTrackerInterface* trackers_[net::NetLog::SOURCE_COUNT]; | 499 SourceTrackerInterface* trackers_[net::NetLog::SOURCE_COUNT]; |
| 483 | 500 |
| 484 // The count of how many events have flowed through this log. Used to set the | 501 // The count of how many events have flowed through this log. Used to set the |
| 485 // "order" field on captured events. | 502 // "order" field on captured events. |
| 486 uint32 num_events_seen_; | 503 uint32 num_events_seen_; |
| 487 | 504 |
| 488 DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector); | 505 DISALLOW_COPY_AND_ASSIGN(PassiveLogCollector); |
| 489 }; | 506 }; |
| 490 | 507 |
| 491 #endif // CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_ | 508 #endif // CHROME_BROWSER_NET_PASSIVE_LOG_COLLECTOR_H_ |
| OLD | NEW |