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_QUIC1_SPDY3: | 121 case net::HttpResponseInfo::CONNECTION_INFO_QUIC: |
122 return "QUIC"; | 122 return "QUIC"; |
123 case net::HttpResponseInfo::NUM_OF_CONNECTION_INFOS: | 123 case net::HttpResponseInfo::NUM_OF_CONNECTION_INFOS: |
124 NOTREACHED(); | 124 NOTREACHED(); |
125 return ""; | 125 return ""; |
126 } | 126 } |
127 NOTREACHED(); | 127 NOTREACHED(); |
128 return ""; | 128 return ""; |
129 } | 129 } |
130 | 130 |
131 int GetNetErrorFromURLRequestStatus(const net::URLRequestStatus& status) { | 131 int GetNetErrorFromURLRequestStatus(const net::URLRequestStatus& status) { |
(...skipping 96 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
228 ActualTime::~ActualTime() {} | 228 ActualTime::~ActualTime() {} |
229 | 229 |
230 base::Time ActualTime::Now() { return base::Time::Now(); } | 230 base::Time ActualTime::Now() { return base::Time::Now(); } |
231 base::TimeTicks ActualTime::NowTicks() { return base::TimeTicks::Now(); } | 231 base::TimeTicks ActualTime::NowTicks() { return base::TimeTicks::Now(); } |
232 | 232 |
233 std::unique_ptr<MockableTime::Timer> ActualTime::CreateTimer() { | 233 std::unique_ptr<MockableTime::Timer> ActualTime::CreateTimer() { |
234 return std::unique_ptr<MockableTime::Timer>(new ActualTimer()); | 234 return std::unique_ptr<MockableTime::Timer>(new ActualTimer()); |
235 } | 235 } |
236 | 236 |
237 } // namespace domain_reliability | 237 } // namespace domain_reliability |
OLD | NEW |