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

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

Issue 11092088: Cleanup referrer_charset (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: sync Created 8 years, 1 month 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
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 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_ 5 #ifndef CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_
6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_ 6 #define CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 virtual bool IsInterrupted() const OVERRIDE; 89 virtual bool IsInterrupted() const OVERRIDE;
90 virtual bool IsComplete() const OVERRIDE; 90 virtual bool IsComplete() const OVERRIDE;
91 virtual const GURL& GetURL() const OVERRIDE; 91 virtual const GURL& GetURL() const OVERRIDE;
92 virtual const std::vector<GURL>& GetUrlChain() const OVERRIDE; 92 virtual const std::vector<GURL>& GetUrlChain() const OVERRIDE;
93 virtual const GURL& GetOriginalUrl() const OVERRIDE; 93 virtual const GURL& GetOriginalUrl() const OVERRIDE;
94 virtual const GURL& GetReferrerUrl() const OVERRIDE; 94 virtual const GURL& GetReferrerUrl() const OVERRIDE;
95 virtual std::string GetSuggestedFilename() const OVERRIDE; 95 virtual std::string GetSuggestedFilename() const OVERRIDE;
96 virtual std::string GetContentDisposition() const OVERRIDE; 96 virtual std::string GetContentDisposition() const OVERRIDE;
97 virtual std::string GetMimeType() const OVERRIDE; 97 virtual std::string GetMimeType() const OVERRIDE;
98 virtual std::string GetOriginalMimeType() const OVERRIDE; 98 virtual std::string GetOriginalMimeType() const OVERRIDE;
99 virtual std::string GetReferrerCharset() const OVERRIDE;
100 virtual std::string GetRemoteAddress() const OVERRIDE; 99 virtual std::string GetRemoteAddress() const OVERRIDE;
101 virtual bool HasUserGesture() const OVERRIDE; 100 virtual bool HasUserGesture() const OVERRIDE;
102 virtual content::PageTransition GetTransitionType() const OVERRIDE; 101 virtual content::PageTransition GetTransitionType() const OVERRIDE;
103 virtual const std::string& GetLastModifiedTime() const OVERRIDE; 102 virtual const std::string& GetLastModifiedTime() const OVERRIDE;
104 virtual const std::string& GetETag() const OVERRIDE; 103 virtual const std::string& GetETag() const OVERRIDE;
105 virtual const FilePath& GetFullPath() const OVERRIDE; 104 virtual const FilePath& GetFullPath() const OVERRIDE;
106 virtual const FilePath& GetTargetFilePath() const OVERRIDE; 105 virtual const FilePath& GetTargetFilePath() const OVERRIDE;
107 virtual const FilePath& GetForcedFilePath() const OVERRIDE; 106 virtual const FilePath& GetForcedFilePath() const OVERRIDE;
108 virtual FilePath GetUserVerifiedFilePath() const OVERRIDE; 107 virtual FilePath GetUserVerifiedFilePath() const OVERRIDE;
109 virtual FilePath GetFileNameToReportUser() const OVERRIDE; 108 virtual FilePath GetFileNameToReportUser() const OVERRIDE;
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after
377 std::string content_disposition_; 376 std::string content_disposition_;
378 377
379 // Mime-type from the header. Subject to change. 378 // Mime-type from the header. Subject to change.
380 std::string mime_type_; 379 std::string mime_type_;
381 380
382 // The value of the content type header sent with the downloaded item. It 381 // The value of the content type header sent with the downloaded item. It
383 // may be different from |mime_type_|, which may be set based on heuristics 382 // may be different from |mime_type_|, which may be set based on heuristics
384 // which may look at the file extension and first few bytes of the file. 383 // which may look at the file extension and first few bytes of the file.
385 std::string original_mime_type_; 384 std::string original_mime_type_;
386 385
387 // The charset of the referring page where the download request comes from.
388 // It's used to construct a suggested filename.
389 std::string referrer_charset_;
390
391 // The remote IP address where the download was fetched from. Copied from 386 // The remote IP address where the download was fetched from. Copied from
392 // DownloadCreateInfo::remote_address. 387 // DownloadCreateInfo::remote_address.
393 std::string remote_address_; 388 std::string remote_address_;
394 389
395 // Total bytes expected. 390 // Total bytes expected.
396 int64 total_bytes_; 391 int64 total_bytes_;
397 392
398 // Current received bytes. 393 // Current received bytes.
399 int64 received_bytes_; 394 int64 received_bytes_;
400 395
(...skipping 88 matching lines...) Expand 10 before | Expand all | Expand 10 after
489 484
490 // Net log to use for this download. 485 // Net log to use for this download.
491 const net::BoundNetLog bound_net_log_; 486 const net::BoundNetLog bound_net_log_;
492 487
493 base::WeakPtrFactory<DownloadItemImpl> weak_ptr_factory_; 488 base::WeakPtrFactory<DownloadItemImpl> weak_ptr_factory_;
494 489
495 DISALLOW_COPY_AND_ASSIGN(DownloadItemImpl); 490 DISALLOW_COPY_AND_ASSIGN(DownloadItemImpl);
496 }; 491 };
497 492
498 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_ 493 #endif // CONTENT_BROWSER_DOWNLOAD_DOWNLOAD_ITEM_IMPL_H_
OLDNEW
« no previous file with comments | « content/browser/download/download_create_info.h ('k') | content/browser/download/download_item_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698