| 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 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_MANAGER_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_MANAGER_IMPL_H_ |
| 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_MANAGER_IMPL_H_ | 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_MANAGER_IMPL_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <set> | 9 #include <set> |
| 10 | 10 |
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 74 scoped_ptr<content::DownloadUrlParameters> params) OVERRIDE; | 74 scoped_ptr<content::DownloadUrlParameters> params) OVERRIDE; |
| 75 virtual void AddObserver(Observer* observer) OVERRIDE; | 75 virtual void AddObserver(Observer* observer) OVERRIDE; |
| 76 virtual void RemoveObserver(Observer* observer) OVERRIDE; | 76 virtual void RemoveObserver(Observer* observer) OVERRIDE; |
| 77 virtual void OnPersistentStoreQueryComplete( | 77 virtual void OnPersistentStoreQueryComplete( |
| 78 std::vector<content::DownloadPersistentStoreInfo>* entries) OVERRIDE; | 78 std::vector<content::DownloadPersistentStoreInfo>* entries) OVERRIDE; |
| 79 virtual void OnItemAddedToPersistentStore(int32 download_id, | 79 virtual void OnItemAddedToPersistentStore(int32 download_id, |
| 80 int64 db_handle) OVERRIDE; | 80 int64 db_handle) OVERRIDE; |
| 81 virtual int InProgressCount() const OVERRIDE; | 81 virtual int InProgressCount() const OVERRIDE; |
| 82 virtual content::BrowserContext* GetBrowserContext() const OVERRIDE; | 82 virtual content::BrowserContext* GetBrowserContext() const OVERRIDE; |
| 83 virtual void CheckForHistoryFilesRemoval() OVERRIDE; | 83 virtual void CheckForHistoryFilesRemoval() OVERRIDE; |
| 84 virtual content::DownloadItem* GetDownloadItem(int id) OVERRIDE; | |
| 85 virtual content::DownloadItem* GetDownload(int id) OVERRIDE; | 84 virtual content::DownloadItem* GetDownload(int id) OVERRIDE; |
| 86 virtual void SavePageDownloadFinished( | 85 virtual void SavePageDownloadFinished( |
| 87 content::DownloadItem* download) OVERRIDE; | 86 content::DownloadItem* download) OVERRIDE; |
| 88 virtual content::DownloadItem* GetActiveDownloadItem(int id) OVERRIDE; | |
| 89 | 87 |
| 90 private: | 88 private: |
| 91 typedef std::set<content::DownloadItem*> DownloadSet; | 89 typedef std::set<content::DownloadItem*> DownloadSet; |
| 92 typedef base::hash_map<int32, DownloadItemImpl*> DownloadMap; | 90 typedef base::hash_map<int32, DownloadItemImpl*> DownloadMap; |
| 93 typedef std::vector<DownloadItemImpl*> DownloadItemImplVector; | 91 typedef std::vector<DownloadItemImpl*> DownloadItemImplVector; |
| 94 | 92 |
| 95 // For testing. | 93 // For testing. |
| 96 friend class DownloadManagerTest; | 94 friend class DownloadManagerTest; |
| 97 friend class DownloadTest; | 95 friend class DownloadTest; |
| 98 | 96 |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 | 224 |
| 227 // Allows an embedder to control behavior. Guaranteed to outlive this object. | 225 // Allows an embedder to control behavior. Guaranteed to outlive this object. |
| 228 content::DownloadManagerDelegate* delegate_; | 226 content::DownloadManagerDelegate* delegate_; |
| 229 | 227 |
| 230 net::NetLog* net_log_; | 228 net::NetLog* net_log_; |
| 231 | 229 |
| 232 DISALLOW_COPY_AND_ASSIGN(DownloadManagerImpl); | 230 DISALLOW_COPY_AND_ASSIGN(DownloadManagerImpl); |
| 233 }; | 231 }; |
| 234 | 232 |
| 235 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_MANAGER_IMPL_H_ | 233 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_MANAGER_IMPL_H_ |
| OLD | NEW |