Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(59)

Side by Side Diff: content/browser/download/download_item_factory.h

Issue 10535135: Made ownership of DownloadRequestHandles clear through scoped_ptr<> (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | content/browser/download/download_item_impl.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 // The DownloadItemFactory is used to produce different DownloadItems. 5 // The DownloadItemFactory is used to produce different DownloadItems.
6 // It is separate from the DownloadManager to allow download manager 6 // It is separate from the DownloadManager to allow download manager
7 // unit tests to control the items produced. 7 // unit tests to control the items produced.
8 8
9 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_FACTORY_H_ 9 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_FACTORY_H_
10 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_FACTORY_H_ 10 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_FACTORY_H_
11 #pragma once 11 #pragma once
12 12
13 #include "content/browser/download/download_item_impl.h" 13 #include "content/browser/download/download_item_impl.h"
Alexander Potapenko 2012/06/12 19:30:06 I'm no good at Chromium style, but shouldn't this
Randy Smith (Not in Mondays) 2012/06/12 19:37:30 Whoops--that was a copy and paste error + confusio
14 14
15 #include <string> 15 #include <string>
16 16
17 #include "base/memory/scoped_ptr.h"
18
17 struct DownloadCreateInfo; 19 struct DownloadCreateInfo;
18 class DownloadRequestHandleInterface; 20 class DownloadRequestHandleInterface;
19 class FilePath; 21 class FilePath;
20 class GURL; 22 class GURL;
21 23
22 namespace content { 24 namespace content {
23 class DownloadId; 25 class DownloadId;
24 class DownloadItem; 26 class DownloadItem;
25 struct DownloadPersistentStoreInfo; 27 struct DownloadPersistentStoreInfo;
26 } 28 }
(...skipping 10 matching lines...) Expand all
37 39
38 virtual content::DownloadItem* CreatePersistedItem( 40 virtual content::DownloadItem* CreatePersistedItem(
39 DownloadItemImpl::Delegate* delegate, 41 DownloadItemImpl::Delegate* delegate,
40 content::DownloadId download_id, 42 content::DownloadId download_id,
41 const content::DownloadPersistentStoreInfo& info, 43 const content::DownloadPersistentStoreInfo& info,
42 const net::BoundNetLog& bound_net_log) = 0; 44 const net::BoundNetLog& bound_net_log) = 0;
43 45
44 virtual content::DownloadItem* CreateActiveItem( 46 virtual content::DownloadItem* CreateActiveItem(
45 DownloadItemImpl::Delegate* delegate, 47 DownloadItemImpl::Delegate* delegate,
46 const DownloadCreateInfo& info, 48 const DownloadCreateInfo& info,
47 DownloadRequestHandleInterface* request_handle, 49 scoped_ptr<DownloadRequestHandleInterface> request_handle,
48 bool is_otr, 50 bool is_otr,
49 const net::BoundNetLog& bound_net_log) = 0; 51 const net::BoundNetLog& bound_net_log) = 0;
50 52
51 virtual content::DownloadItem* CreateSavePageItem( 53 virtual content::DownloadItem* CreateSavePageItem(
52 DownloadItemImpl::Delegate* delegate, 54 DownloadItemImpl::Delegate* delegate,
53 const FilePath& path, 55 const FilePath& path,
54 const GURL& url, 56 const GURL& url,
55 bool is_otr, 57 bool is_otr,
56 content::DownloadId download_id, 58 content::DownloadId download_id,
57 const std::string& mime_type, 59 const std::string& mime_type,
58 const net::BoundNetLog& bound_net_log) = 0; 60 const net::BoundNetLog& bound_net_log) = 0;
59 }; 61 };
60 62
61 } // namespace content 63 } // namespace content
62 64
63 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_FACTORY_H_ 65 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_FACTORY_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/download/download_item_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698