| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2008 Apple Inc. All rights reserved. |
| 3 * Copyright (C) 2009 Google Inc. All rights reserved. | 3 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 4 * | 4 * |
| 5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
| 6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
| 7 * are met: | 7 * are met: |
| 8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
| (...skipping 559 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 570 KURL ResourceResponse::OriginalURLViaServiceWorker() const { | 570 KURL ResourceResponse::OriginalURLViaServiceWorker() const { |
| 571 if (url_list_via_service_worker_.IsEmpty()) | 571 if (url_list_via_service_worker_.IsEmpty()) |
| 572 return KURL(); | 572 return KURL(); |
| 573 return url_list_via_service_worker_.back(); | 573 return url_list_via_service_worker_.back(); |
| 574 } | 574 } |
| 575 | 575 |
| 576 void ResourceResponse::SetEncodedDataLength(long long value) { | 576 void ResourceResponse::SetEncodedDataLength(long long value) { |
| 577 encoded_data_length_ = value; | 577 encoded_data_length_ = value; |
| 578 } | 578 } |
| 579 | 579 |
| 580 void ResourceResponse::AddToEncodedBodyLength(long long value) { | 580 void ResourceResponse::SetEncodedBodyLength(long long value) { |
| 581 encoded_body_length_ += value; | 581 encoded_body_length_ = value; |
| 582 } | 582 } |
| 583 | 583 |
| 584 void ResourceResponse::AddToDecodedBodyLength(long long value) { | 584 void ResourceResponse::SetDecodedBodyLength(long long value) { |
| 585 decoded_body_length_ += value; | 585 decoded_body_length_ = value; |
| 586 } | 586 } |
| 587 | 587 |
| 588 void ResourceResponse::SetDownloadedFilePath( | 588 void ResourceResponse::SetDownloadedFilePath( |
| 589 const String& downloaded_file_path) { | 589 const String& downloaded_file_path) { |
| 590 downloaded_file_path_ = downloaded_file_path; | 590 downloaded_file_path_ = downloaded_file_path; |
| 591 if (downloaded_file_path_.IsEmpty()) { | 591 if (downloaded_file_path_.IsEmpty()) { |
| 592 downloaded_file_handle_.Clear(); | 592 downloaded_file_handle_.Clear(); |
| 593 return; | 593 return; |
| 594 } | 594 } |
| 595 // TODO(dmurph): Investigate whether we need the mimeType on this blob. | 595 // TODO(dmurph): Investigate whether we need the mimeType on this blob. |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 628 if (a.GetResourceLoadTiming() != b.GetResourceLoadTiming()) | 628 if (a.GetResourceLoadTiming() != b.GetResourceLoadTiming()) |
| 629 return false; | 629 return false; |
| 630 if (a.EncodedBodyLength() != b.EncodedBodyLength()) | 630 if (a.EncodedBodyLength() != b.EncodedBodyLength()) |
| 631 return false; | 631 return false; |
| 632 if (a.DecodedBodyLength() != b.DecodedBodyLength()) | 632 if (a.DecodedBodyLength() != b.DecodedBodyLength()) |
| 633 return false; | 633 return false; |
| 634 return true; | 634 return true; |
| 635 } | 635 } |
| 636 | 636 |
| 637 } // namespace blink | 637 } // namespace blink |
| OLD | NEW |