| 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 "net/http/http_request_headers.h" | 5 #include "net/http/http_request_headers.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/strings/string_split.h" | 8 #include "base/strings/string_split.h" |
| 9 #include "base/strings/string_util.h" | 9 #include "base/strings/string_util.h" |
| 10 #include "base/strings/stringprintf.h" | 10 #include "base/strings/stringprintf.h" |
| (...skipping 16 matching lines...) Expand all Loading... |
| 27 const char HttpRequestHeaders::kHost[] = "Host"; | 27 const char HttpRequestHeaders::kHost[] = "Host"; |
| 28 const char HttpRequestHeaders::kIfModifiedSince[] = "If-Modified-Since"; | 28 const char HttpRequestHeaders::kIfModifiedSince[] = "If-Modified-Since"; |
| 29 const char HttpRequestHeaders::kIfNoneMatch[] = "If-None-Match"; | 29 const char HttpRequestHeaders::kIfNoneMatch[] = "If-None-Match"; |
| 30 const char HttpRequestHeaders::kIfRange[] = "If-Range"; | 30 const char HttpRequestHeaders::kIfRange[] = "If-Range"; |
| 31 const char HttpRequestHeaders::kOrigin[] = "Origin"; | 31 const char HttpRequestHeaders::kOrigin[] = "Origin"; |
| 32 const char HttpRequestHeaders::kPragma[] = "Pragma"; | 32 const char HttpRequestHeaders::kPragma[] = "Pragma"; |
| 33 const char HttpRequestHeaders::kProxyAuthorization[] = "Proxy-Authorization"; | 33 const char HttpRequestHeaders::kProxyAuthorization[] = "Proxy-Authorization"; |
| 34 const char HttpRequestHeaders::kProxyConnection[] = "Proxy-Connection"; | 34 const char HttpRequestHeaders::kProxyConnection[] = "Proxy-Connection"; |
| 35 const char HttpRequestHeaders::kRange[] = "Range"; | 35 const char HttpRequestHeaders::kRange[] = "Range"; |
| 36 const char HttpRequestHeaders::kReferer[] = "Referer"; | 36 const char HttpRequestHeaders::kReferer[] = "Referer"; |
| 37 const char HttpRequestHeaders::kTransferEncoding[] = "Transfer-Encoding"; |
| 38 const char HttpRequestHeaders::kTokenBinding[] = "Token-Binding"; |
| 37 const char HttpRequestHeaders::kUserAgent[] = "User-Agent"; | 39 const char HttpRequestHeaders::kUserAgent[] = "User-Agent"; |
| 38 const char HttpRequestHeaders::kTransferEncoding[] = "Transfer-Encoding"; | |
| 39 | 40 |
| 40 HttpRequestHeaders::HeaderKeyValuePair::HeaderKeyValuePair() { | 41 HttpRequestHeaders::HeaderKeyValuePair::HeaderKeyValuePair() { |
| 41 } | 42 } |
| 42 | 43 |
| 43 HttpRequestHeaders::HeaderKeyValuePair::HeaderKeyValuePair( | 44 HttpRequestHeaders::HeaderKeyValuePair::HeaderKeyValuePair( |
| 44 const base::StringPiece& key, const base::StringPiece& value) | 45 const base::StringPiece& key, const base::StringPiece& value) |
| 45 : key(key.data(), key.size()), value(value.data(), value.size()) { | 46 : key(key.data(), key.size()), value(value.data(), value.size()) { |
| 46 } | 47 } |
| 47 | 48 |
| 48 | 49 |
| (...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 253 for (HeaderVector::const_iterator it = headers_.begin(); | 254 for (HeaderVector::const_iterator it = headers_.begin(); |
| 254 it != headers_.end(); ++it) { | 255 it != headers_.end(); ++it) { |
| 255 if (base::EqualsCaseInsensitiveASCII(key, it->key)) | 256 if (base::EqualsCaseInsensitiveASCII(key, it->key)) |
| 256 return it; | 257 return it; |
| 257 } | 258 } |
| 258 | 259 |
| 259 return headers_.end(); | 260 return headers_.end(); |
| 260 } | 261 } |
| 261 | 262 |
| 262 } // namespace net | 263 } // namespace net |
| OLD | NEW |