OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #include "net/base/net_log.h" | 5 #include "net/base/net_log.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/logging.h" | 8 #include "base/logging.h" |
9 #include "base/strings/string_number_conversions.h" | 9 #include "base/strings/string_number_conversions.h" |
10 #include "base/strings/utf_string_conversions.h" | 10 #include "base/strings/utf_string_conversions.h" |
11 #include "base/time.h" | 11 #include "base/time/time.h" |
12 #include "base/values.h" | 12 #include "base/values.h" |
13 #include "net/base/net_errors.h" | 13 #include "net/base/net_errors.h" |
14 | 14 |
15 namespace net { | 15 namespace net { |
16 | 16 |
17 namespace { | 17 namespace { |
18 | 18 |
19 // Returns parameters for logging data transferred events. Includes number of | 19 // Returns parameters for logging data transferred events. Includes number of |
20 // bytes transferred and, if the log level indicates bytes should be logged and | 20 // bytes transferred and, if the log level indicates bytes should be logged and |
21 // |byte_count| > 0, the bytes themselves. The bytes are hex-encoded, since | 21 // |byte_count| > 0, the bytes themselves. The bytes are hex-encoded, since |
(...skipping 462 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
484 BoundNetLog BoundNetLog::Make(NetLog* net_log, | 484 BoundNetLog BoundNetLog::Make(NetLog* net_log, |
485 NetLog::SourceType source_type) { | 485 NetLog::SourceType source_type) { |
486 if (!net_log) | 486 if (!net_log) |
487 return BoundNetLog(); | 487 return BoundNetLog(); |
488 | 488 |
489 NetLog::Source source(source_type, net_log->NextID()); | 489 NetLog::Source source(source_type, net_log->NextID()); |
490 return BoundNetLog(source, net_log); | 490 return BoundNetLog(source, net_log); |
491 } | 491 } |
492 | 492 |
493 } // namespace net | 493 } // namespace net |
OLD | NEW |