OLD | NEW |
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 #include "webkit/child/multipart_response_delegate.h" | 5 #include "content/child/multipart_response_delegate.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "base/strings/string_number_conversions.h" | 8 #include "base/strings/string_number_conversions.h" |
9 #include "base/strings/string_util.h" | 9 #include "base/strings/string_util.h" |
10 #include "net/base/net_util.h" | 10 #include "net/base/net_util.h" |
11 #include "net/http/http_util.h" | 11 #include "net/http/http_util.h" |
12 #include "third_party/WebKit/public/platform/WebHTTPHeaderVisitor.h" | 12 #include "third_party/WebKit/public/platform/WebHTTPHeaderVisitor.h" |
13 #include "third_party/WebKit/public/platform/WebString.h" | 13 #include "third_party/WebKit/public/platform/WebString.h" |
14 #include "third_party/WebKit/public/platform/WebURL.h" | 14 #include "third_party/WebKit/public/platform/WebURL.h" |
15 #include "third_party/WebKit/public/platform/WebURLLoaderClient.h" | 15 #include "third_party/WebKit/public/platform/WebURLLoaderClient.h" |
16 | 16 |
17 using blink::WebHTTPHeaderVisitor; | 17 using blink::WebHTTPHeaderVisitor; |
18 using blink::WebString; | 18 using blink::WebString; |
19 using blink::WebURLLoader; | 19 using blink::WebURLLoader; |
20 using blink::WebURLLoaderClient; | 20 using blink::WebURLLoaderClient; |
21 using blink::WebURLResponse; | 21 using blink::WebURLResponse; |
22 | 22 |
23 namespace webkit_glue { | 23 namespace content { |
24 | 24 |
25 namespace { | 25 namespace { |
26 | 26 |
27 // The list of response headers that we do not copy from the original | 27 // The list of response headers that we do not copy from the original |
28 // response when generating a WebURLResponse for a MIME payload. | 28 // response when generating a WebURLResponse for a MIME payload. |
29 const char* kReplaceHeaders[] = { | 29 const char* kReplaceHeaders[] = { |
30 "content-type", | 30 "content-type", |
31 "content-length", | 31 "content-length", |
32 "content-disposition", | 32 "content-disposition", |
33 "content-range", | 33 "content-range", |
(...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
394 return false; | 394 return false; |
395 if (!base::StringToInt64(byte_range_upper_bound, content_range_upper_bound)) | 395 if (!base::StringToInt64(byte_range_upper_bound, content_range_upper_bound)) |
396 return false; | 396 return false; |
397 if (!base::StringToInt64(byte_range_instance_size, | 397 if (!base::StringToInt64(byte_range_instance_size, |
398 content_range_instance_size)) { | 398 content_range_instance_size)) { |
399 return false; | 399 return false; |
400 } | 400 } |
401 return true; | 401 return true; |
402 } | 402 } |
403 | 403 |
404 } // namespace webkit_glue | 404 } // namespace content |
OLD | NEW |