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 CHROME_BROWSER_DOWNLOAD_DOWNLOAD_HISTORY_H_ | 5 #ifndef CHROME_BROWSER_DOWNLOAD_DOWNLOAD_HISTORY_H_ |
6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_HISTORY_H_ | 6 #define CHROME_BROWSER_DOWNLOAD_DOWNLOAD_HISTORY_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <map> | 9 #include <map> |
10 | 10 |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 void AddEntry(DownloadItem* download_item, | 45 void AddEntry(DownloadItem* download_item, |
46 HistoryService::DownloadCreateCallback* callback); | 46 HistoryService::DownloadCreateCallback* callback); |
47 | 47 |
48 // Updates the history entry for |download_item|. | 48 // Updates the history entry for |download_item|. |
49 void UpdateEntry(DownloadItem* download_item); | 49 void UpdateEntry(DownloadItem* download_item); |
50 | 50 |
51 // Updates the download path for |download_item| to |new_path|. | 51 // Updates the download path for |download_item| to |new_path|. |
52 void UpdateDownloadPath(DownloadItem* download_item, | 52 void UpdateDownloadPath(DownloadItem* download_item, |
53 const FilePath& new_path); | 53 const FilePath& new_path); |
54 | 54 |
| 55 void MarkDownloadOpened(int64 db_handle); |
| 56 |
55 // Removes |download_item| from the history database. | 57 // Removes |download_item| from the history database. |
56 void RemoveEntry(DownloadItem* download_item); | 58 void RemoveEntry(DownloadItem* download_item); |
57 | 59 |
58 // Removes download-related history entries in the given time range. | 60 // Removes download-related history entries in the given time range. |
59 void RemoveEntriesBetween(const base::Time remove_begin, | 61 void RemoveEntriesBetween(const base::Time remove_begin, |
60 const base::Time remove_end); | 62 const base::Time remove_end); |
61 | 63 |
62 // Returns a new unique database handle which will not collide with real ones. | 64 // Returns a new unique database handle which will not collide with real ones. |
63 int64 GetNextFakeDbHandle(); | 65 int64 GetNextFakeDbHandle(); |
64 | 66 |
(...skipping 17 matching lines...) Expand all Loading... |
82 | 84 |
83 CancelableRequestConsumer history_consumer_; | 85 CancelableRequestConsumer history_consumer_; |
84 | 86 |
85 // The outstanding requests made by CheckVisitedReferrerBefore(). | 87 // The outstanding requests made by CheckVisitedReferrerBefore(). |
86 VisitedBeforeRequestsMap visited_before_requests_; | 88 VisitedBeforeRequestsMap visited_before_requests_; |
87 | 89 |
88 DISALLOW_COPY_AND_ASSIGN(DownloadHistory); | 90 DISALLOW_COPY_AND_ASSIGN(DownloadHistory); |
89 }; | 91 }; |
90 | 92 |
91 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_HISTORY_H_ | 93 #endif // CHROME_BROWSER_DOWNLOAD_DOWNLOAD_HISTORY_H_ |
OLD | NEW |