| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ | 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ |
| 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ | 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 81 std::string content_disposition; | 81 std::string content_disposition; |
| 82 | 82 |
| 83 // The mime type string from the response header (may be overridden). | 83 // The mime type string from the response header (may be overridden). |
| 84 std::string mime_type; | 84 std::string mime_type; |
| 85 | 85 |
| 86 // The value of the content type header sent with the downloaded item. It | 86 // The value of the content type header sent with the downloaded item. It |
| 87 // may be different from |mime_type|, which may be set based on heuristics | 87 // may be different from |mime_type|, which may be set based on heuristics |
| 88 // which may look at the file extension and first few bytes of the file. | 88 // which may look at the file extension and first few bytes of the file. |
| 89 std::string original_mime_type; | 89 std::string original_mime_type; |
| 90 | 90 |
| 91 // For continuing a download, the modification time of the file. |
| 92 // Storing as a string for exact match to server format on |
| 93 // "If-Unmodified-Since" comparison. |
| 94 std::string last_modified; |
| 95 |
| 96 // For continuing a download, the ETAG of the file. |
| 97 std::string etag; |
| 98 |
| 91 // True if we should display the 'save as...' UI and prompt the user | 99 // True if we should display the 'save as...' UI and prompt the user |
| 92 // for the download location. | 100 // for the download location. |
| 93 // False if the UI should be supressed and the download performed to the | 101 // False if the UI should be suppressed and the download performed to the |
| 94 // default location. | 102 // default location. |
| 95 bool prompt_user_for_save_location; | 103 bool prompt_user_for_save_location; |
| 96 | 104 |
| 97 // The original name for a dangerous download. | 105 // The original name for a dangerous download. |
| 98 FilePath original_name; | 106 FilePath original_name; |
| 99 | 107 |
| 100 // The charset of the referring page where the download request comes from. | 108 // The charset of the referring page where the download request comes from. |
| 101 // It's used to construct a suggested filename. | 109 // It's used to construct a suggested filename. |
| 102 std::string referrer_charset; | 110 std::string referrer_charset; |
| 103 | 111 |
| 104 // The download file save info. | 112 // The download file save info. |
| 105 DownloadSaveInfo save_info; | 113 DownloadSaveInfo save_info; |
| 106 | 114 |
| 107 // The remote IP address where the download was fetched from. Copied from | 115 // The remote IP address where the download was fetched from. Copied from |
| 108 // UrlRequest::GetSocketAddress(). | 116 // UrlRequest::GetSocketAddress(). |
| 109 std::string remote_address; | 117 std::string remote_address; |
| 110 }; | 118 }; |
| 111 | 119 |
| 112 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ | 120 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_CREATE_INFO_H_ |
| OLD | NEW |