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

Side by Side Diff: content/child/multipart_response_delegate.h

Issue 1662013002: Remove some dead NPAPI code after r363119. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove unused functions Created 4 years, 10 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
« no previous file with comments | « no previous file | content/child/multipart_response_delegate.cc » ('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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // A delegate class of WebURLLoaderImpl that handles multipart/x-mixed-replace 5 // A delegate class of WebURLLoaderImpl that handles multipart/x-mixed-replace
6 // data. We special case multipart/x-mixed-replace because WebCore expects a 6 // data. We special case multipart/x-mixed-replace because WebCore expects a
7 // separate didReceiveResponse for each new message part. 7 // separate didReceiveResponse for each new message part.
8 // 8 //
9 // Most of the logic and edge case handling are based on the Mozilla's 9 // Most of the logic and edge case handling are based on the Mozilla's
10 // implementation in netwerk/streamconv/converters/nsMultiMixedConv.cpp. 10 // implementation in netwerk/streamconv/converters/nsMultiMixedConv.cpp.
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 // Passed through from ResourceHandleInternal 76 // Passed through from ResourceHandleInternal
77 void OnReceivedData(const char* data, int data_len, int encoded_data_length); 77 void OnReceivedData(const char* data, int data_len, int encoded_data_length);
78 void OnCompletedRequest(); 78 void OnCompletedRequest();
79 79
80 // The request has been canceled, so stop making calls to the client. 80 // The request has been canceled, so stop making calls to the client.
81 void Cancel() { 81 void Cancel() {
82 client_ = NULL; 82 client_ = NULL;
83 loader_ = NULL; 83 loader_ = NULL;
84 } 84 }
85 85
86 // Returns the multi part boundary string from the Content-type header
87 // in the response.
88 // Returns true on success.
89 static bool ReadMultipartBoundary(const blink::WebURLResponse& response,
90 std::string* multipart_boundary);
91
92 // Returns the lower and higher content ranges from an individual multipart 86 // Returns the lower and higher content ranges from an individual multipart
93 // in a multipart response. 87 // in a multipart response.
94 // Returns true on success. 88 // Returns true on success.
95 static bool ReadContentRanges(const blink::WebURLResponse& response, 89 static bool ReadContentRanges(const blink::WebURLResponse& response,
96 int64_t* content_range_lower_bound, 90 int64_t* content_range_lower_bound,
97 int64_t* content_range_upper_bound, 91 int64_t* content_range_upper_bound,
98 int64_t* content_range_instance_size); 92 int64_t* content_range_instance_size);
99 93
100 private: 94 private:
101 friend class MultipartResponseDelegateTester; // For unittests. 95 friend class MultipartResponseDelegateTester; // For unittests.
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
144 138
145 // true after we've sent our first response to the WebURLLoaderClient. 139 // true after we've sent our first response to the WebURLLoaderClient.
146 bool has_sent_first_response_; 140 bool has_sent_first_response_;
147 141
148 DISALLOW_COPY_AND_ASSIGN(MultipartResponseDelegate); 142 DISALLOW_COPY_AND_ASSIGN(MultipartResponseDelegate);
149 }; 143 };
150 144
151 } // namespace content 145 } // namespace content
152 146
153 #endif // CONTENT_CHILD_MULTIPART_RESPONSE_DELEGATE_H_ 147 #endif // CONTENT_CHILD_MULTIPART_RESPONSE_DELEGATE_H_
OLDNEW
« no previous file with comments | « no previous file | content/child/multipart_response_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698