OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 #include "content/public/test/fake_download_item.h" | 5 #include "content/public/test/fake_download_item.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 | 8 |
9 namespace content { | 9 namespace content { |
10 | 10 |
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
62 } | 62 } |
63 | 63 |
64 void FakeDownloadItem::SetURL(const GURL& url) { | 64 void FakeDownloadItem::SetURL(const GURL& url) { |
65 url_ = url; | 65 url_ = url; |
66 } | 66 } |
67 | 67 |
68 const GURL& FakeDownloadItem::GetURL() const { | 68 const GURL& FakeDownloadItem::GetURL() const { |
69 return url_; | 69 return url_; |
70 } | 70 } |
71 | 71 |
| 72 void FakeDownloadItem::SetLastReason(DownloadInterruptReason last_reason) { |
| 73 last_reason_ = last_reason; |
| 74 } |
| 75 |
| 76 DownloadInterruptReason FakeDownloadItem::GetLastReason() const { |
| 77 return last_reason_; |
| 78 } |
| 79 |
72 void FakeDownloadItem::SetTargetFilePath(const base::FilePath& file_path) { | 80 void FakeDownloadItem::SetTargetFilePath(const base::FilePath& file_path) { |
73 file_path_ = file_path; | 81 file_path_ = file_path; |
74 } | 82 } |
75 | 83 |
76 const base::FilePath& FakeDownloadItem::GetTargetFilePath() const { | 84 const base::FilePath& FakeDownloadItem::GetTargetFilePath() const { |
77 return file_path_; | 85 return file_path_; |
78 } | 86 } |
79 | 87 |
80 void FakeDownloadItem::SetFileExternallyRemoved( | 88 void FakeDownloadItem::SetFileExternallyRemoved( |
81 bool is_file_externally_removed) { | 89 bool is_file_externally_removed) { |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 } | 163 } |
156 | 164 |
157 void FakeDownloadItem::OpenDownload() { | 165 void FakeDownloadItem::OpenDownload() { |
158 NOTREACHED(); | 166 NOTREACHED(); |
159 } | 167 } |
160 | 168 |
161 void FakeDownloadItem::ShowDownloadInShell() { | 169 void FakeDownloadItem::ShowDownloadInShell() { |
162 NOTREACHED(); | 170 NOTREACHED(); |
163 } | 171 } |
164 | 172 |
165 DownloadInterruptReason FakeDownloadItem::GetLastReason() const { | |
166 NOTREACHED(); | |
167 return DownloadInterruptReason(); | |
168 } | |
169 | |
170 bool FakeDownloadItem::IsPaused() const { | 173 bool FakeDownloadItem::IsPaused() const { |
171 NOTREACHED(); | 174 NOTREACHED(); |
172 return false; | 175 return false; |
173 } | 176 } |
174 | 177 |
175 bool FakeDownloadItem::IsTemporary() const { | 178 bool FakeDownloadItem::IsTemporary() const { |
176 NOTREACHED(); | 179 NOTREACHED(); |
177 return false; | 180 return false; |
178 } | 181 } |
179 | 182 |
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 void FakeDownloadItem::SetDisplayName(const base::FilePath& name) { | 401 void FakeDownloadItem::SetDisplayName(const base::FilePath& name) { |
399 NOTREACHED(); | 402 NOTREACHED(); |
400 } | 403 } |
401 | 404 |
402 std::string FakeDownloadItem::DebugString(bool verbose) const { | 405 std::string FakeDownloadItem::DebugString(bool verbose) const { |
403 NOTREACHED(); | 406 NOTREACHED(); |
404 return std::string(); | 407 return std::string(); |
405 } | 408 } |
406 | 409 |
407 } // namespace content | 410 } // namespace content |
OLD | NEW |