OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "components/domain_reliability/util.h" | 5 #include "components/domain_reliability/util.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/callback.h" | 9 #include "base/callback.h" |
10 #include "base/logging.h" | 10 #include "base/logging.h" |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
111 case net::HttpResponseInfo::CONNECTION_INFO_HTTP0_9: | 111 case net::HttpResponseInfo::CONNECTION_INFO_HTTP0_9: |
112 case net::HttpResponseInfo::CONNECTION_INFO_HTTP1_0: | 112 case net::HttpResponseInfo::CONNECTION_INFO_HTTP1_0: |
113 case net::HttpResponseInfo::CONNECTION_INFO_HTTP1_1: | 113 case net::HttpResponseInfo::CONNECTION_INFO_HTTP1_1: |
114 return ssl_info_populated ? "HTTPS" : "HTTP"; | 114 return ssl_info_populated ? "HTTPS" : "HTTP"; |
115 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_SPDY2: | 115 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_SPDY2: |
116 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_SPDY3: | 116 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_SPDY3: |
117 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_HTTP2_14: | 117 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_HTTP2_14: |
118 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_HTTP2_15: | 118 case net::HttpResponseInfo::CONNECTION_INFO_DEPRECATED_HTTP2_15: |
119 case net::HttpResponseInfo::CONNECTION_INFO_HTTP2: | 119 case net::HttpResponseInfo::CONNECTION_INFO_HTTP2: |
120 return "SPDY"; | 120 return "SPDY"; |
121 case net::HttpResponseInfo::CONNECTION_INFO_QUIC: | 121 case net::HttpResponseInfo::CONNECTION_INFO_QUIC_UNKNOWN_VERSION: |
| 122 case net::HttpResponseInfo::CONNECTION_INFO_QUIC_32: |
| 123 case net::HttpResponseInfo::CONNECTION_INFO_QUIC_33: |
| 124 case net::HttpResponseInfo::CONNECTION_INFO_QUIC_34: |
| 125 case net::HttpResponseInfo::CONNECTION_INFO_QUIC_35: |
| 126 case net::HttpResponseInfo::CONNECTION_INFO_QUIC_36: |
122 return "QUIC"; | 127 return "QUIC"; |
123 case net::HttpResponseInfo::NUM_OF_CONNECTION_INFOS: | 128 case net::HttpResponseInfo::NUM_OF_CONNECTION_INFOS: |
124 NOTREACHED(); | 129 NOTREACHED(); |
125 return ""; | 130 return ""; |
126 } | 131 } |
127 NOTREACHED(); | 132 NOTREACHED(); |
128 return ""; | 133 return ""; |
129 } | 134 } |
130 | 135 |
131 int GetNetErrorFromURLRequestStatus(const net::URLRequestStatus& status) { | 136 int GetNetErrorFromURLRequestStatus(const net::URLRequestStatus& status) { |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 ActualTime::~ActualTime() {} | 233 ActualTime::~ActualTime() {} |
229 | 234 |
230 base::Time ActualTime::Now() { return base::Time::Now(); } | 235 base::Time ActualTime::Now() { return base::Time::Now(); } |
231 base::TimeTicks ActualTime::NowTicks() { return base::TimeTicks::Now(); } | 236 base::TimeTicks ActualTime::NowTicks() { return base::TimeTicks::Now(); } |
232 | 237 |
233 std::unique_ptr<MockableTime::Timer> ActualTime::CreateTimer() { | 238 std::unique_ptr<MockableTime::Timer> ActualTime::CreateTimer() { |
234 return std::unique_ptr<MockableTime::Timer>(new ActualTimer()); | 239 return std::unique_ptr<MockableTime::Timer>(new ActualTimer()); |
235 } | 240 } |
236 | 241 |
237 } // namespace domain_reliability | 242 } // namespace domain_reliability |
OLD | NEW |