| 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/http/http_network_transaction.h" | 5 #include "net/http/http_network_transaction.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 371 return LOAD_STATE_SENDING_REQUEST; | 371 return LOAD_STATE_SENDING_REQUEST; |
| 372 case STATE_READ_HEADERS_COMPLETE: | 372 case STATE_READ_HEADERS_COMPLETE: |
| 373 return LOAD_STATE_WAITING_FOR_RESPONSE; | 373 return LOAD_STATE_WAITING_FOR_RESPONSE; |
| 374 case STATE_READ_BODY_COMPLETE: | 374 case STATE_READ_BODY_COMPLETE: |
| 375 return LOAD_STATE_READING_RESPONSE; | 375 return LOAD_STATE_READING_RESPONSE; |
| 376 default: | 376 default: |
| 377 return LOAD_STATE_IDLE; | 377 return LOAD_STATE_IDLE; |
| 378 } | 378 } |
| 379 } | 379 } |
| 380 | 380 |
| 381 UploadProgress HttpNetworkTransaction::GetUploadProgress() const { | |
| 382 if (!stream_.get()) | |
| 383 return UploadProgress(); | |
| 384 | |
| 385 return stream_->GetUploadProgress(); | |
| 386 } | |
| 387 | |
| 388 void HttpNetworkTransaction::SetQuicServerInfo( | 381 void HttpNetworkTransaction::SetQuicServerInfo( |
| 389 QuicServerInfo* quic_server_info) {} | 382 QuicServerInfo* quic_server_info) {} |
| 390 | 383 |
| 391 bool HttpNetworkTransaction::GetLoadTimingInfo( | 384 bool HttpNetworkTransaction::GetLoadTimingInfo( |
| 392 LoadTimingInfo* load_timing_info) const { | 385 LoadTimingInfo* load_timing_info) const { |
| 393 if (!stream_ || !stream_->GetLoadTimingInfo(load_timing_info)) | 386 if (!stream_ || !stream_->GetLoadTimingInfo(load_timing_info)) |
| 394 return false; | 387 return false; |
| 395 | 388 |
| 396 load_timing_info->proxy_resolve_start = | 389 load_timing_info->proxy_resolve_start = |
| 397 proxy_info_.proxy_resolve_start_time(); | 390 proxy_info_.proxy_resolve_start_time(); |
| (...skipping 1238 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1636 DCHECK(stream_request_); | 1629 DCHECK(stream_request_); |
| 1637 | 1630 |
| 1638 // Since the transaction can restart with auth credentials, it may create a | 1631 // Since the transaction can restart with auth credentials, it may create a |
| 1639 // stream more than once. Accumulate all of the connection attempts across | 1632 // stream more than once. Accumulate all of the connection attempts across |
| 1640 // those streams by appending them to the vector: | 1633 // those streams by appending them to the vector: |
| 1641 for (const auto& attempt : stream_request_->connection_attempts()) | 1634 for (const auto& attempt : stream_request_->connection_attempts()) |
| 1642 connection_attempts_.push_back(attempt); | 1635 connection_attempts_.push_back(attempt); |
| 1643 } | 1636 } |
| 1644 | 1637 |
| 1645 } // namespace net | 1638 } // namespace net |
| OLD | NEW |