OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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_CHILD_NPAPI_URL_FETCHER_H_ | 5 #ifndef CONTENT_CHILD_NPAPI_URL_FETCHER_H_ |
6 #define CONTENT_CHILD_NPAPI_URL_FETCHER_H_ | 6 #define CONTENT_CHILD_NPAPI_URL_FETCHER_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
49 GURL referrer() { return referrer_; } | 49 GURL referrer() { return referrer_; } |
50 int origin_pid() { return origin_pid_; } | 50 int origin_pid() { return origin_pid_; } |
51 int render_frame_id() { return render_frame_id_; } | 51 int render_frame_id() { return render_frame_id_; } |
52 int render_view_id() { return render_view_id_; } | 52 int render_view_id() { return render_view_id_; } |
53 bool copy_stream_data() { return copy_stream_data_; } | 53 bool copy_stream_data() { return copy_stream_data_; } |
54 bool pending_failure_notification() { return pending_failure_notification_; } | 54 bool pending_failure_notification() { return pending_failure_notification_; } |
55 | 55 |
56 private: | 56 private: |
57 // RequestPeer implementation: | 57 // RequestPeer implementation: |
58 virtual void OnUploadProgress(uint64 position, uint64 size) OVERRIDE; | 58 virtual void OnUploadProgress(uint64 position, uint64 size) OVERRIDE; |
59 virtual bool OnReceivedRedirect(const GURL& new_url, | 59 virtual bool OnReceivedRedirect(const net::RedirectInfo& redirect_info, |
60 const GURL& new_first_party_for_cookies, | |
61 const ResourceResponseInfo& info) OVERRIDE; | 60 const ResourceResponseInfo& info) OVERRIDE; |
62 virtual void OnReceivedResponse(const ResourceResponseInfo& info) OVERRIDE; | 61 virtual void OnReceivedResponse(const ResourceResponseInfo& info) OVERRIDE; |
63 virtual void OnDownloadedData(int len, int encoded_data_length) OVERRIDE; | 62 virtual void OnDownloadedData(int len, int encoded_data_length) OVERRIDE; |
64 virtual void OnReceivedData(const char* data, | 63 virtual void OnReceivedData(const char* data, |
65 int data_length, | 64 int data_length, |
66 int encoded_data_length) OVERRIDE; | 65 int encoded_data_length) OVERRIDE; |
67 virtual void OnCompletedRequest(int error_code, | 66 virtual void OnCompletedRequest(int error_code, |
68 bool was_ignored_by_handler, | 67 bool was_ignored_by_handler, |
69 bool stale_copy_in_cache, | 68 bool stale_copy_in_cache, |
70 const std::string& security_info, | 69 const std::string& security_info, |
71 const base::TimeTicks& completion_time, | 70 const base::TimeTicks& completion_time, |
72 int64 total_transfer_size) OVERRIDE; | 71 int64 total_transfer_size) OVERRIDE; |
73 | 72 |
74 // |plugin_stream_| becomes NULL after Cancel() to ensure no further calls | 73 // |plugin_stream_| becomes NULL after Cancel() to ensure no further calls |
75 // |reach it. | 74 // |reach it. |
76 PluginStreamUrl* plugin_stream_; | 75 PluginStreamUrl* plugin_stream_; |
77 GURL url_; | 76 GURL url_; |
78 GURL first_party_for_cookies_; | 77 GURL first_party_for_cookies_; |
79 std::string method_; | |
80 GURL referrer_; | 78 GURL referrer_; |
81 bool notify_redirects_; | 79 bool notify_redirects_; |
82 bool is_plugin_src_load_; | 80 bool is_plugin_src_load_; |
83 int origin_pid_; | 81 int origin_pid_; |
84 int render_frame_id_; | 82 int render_frame_id_; |
85 int render_view_id_; | 83 int render_view_id_; |
86 unsigned long resource_id_; | 84 unsigned long resource_id_; |
87 bool copy_stream_data_; | 85 bool copy_stream_data_; |
88 int64 data_offset_; | 86 int64 data_offset_; |
89 bool pending_failure_notification_; | 87 bool pending_failure_notification_; |
90 | 88 |
91 scoped_ptr<MultipartResponseDelegate> multipart_delegate_; | 89 scoped_ptr<MultipartResponseDelegate> multipart_delegate_; |
92 | 90 |
93 scoped_ptr<webkit_glue::ResourceLoaderBridge> bridge_; | 91 scoped_ptr<webkit_glue::ResourceLoaderBridge> bridge_; |
94 | 92 |
95 DISALLOW_COPY_AND_ASSIGN(PluginURLFetcher); | 93 DISALLOW_COPY_AND_ASSIGN(PluginURLFetcher); |
96 }; | 94 }; |
97 | 95 |
98 } // namespace content | 96 } // namespace content |
99 | 97 |
100 #endif // CONTENT_CHILD_NPAPI_URL_FETCHER_H_ | 98 #endif // CONTENT_CHILD_NPAPI_URL_FETCHER_H_ |
OLD | NEW |