OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 URL_URL_PARSE_INTERNAL_H_ | 5 #ifndef URL_URL_PARSE_INTERNAL_H_ |
6 #define URL_URL_PARSE_INTERNAL_H_ | 6 #define URL_URL_PARSE_INTERNAL_H_ |
7 | 7 |
8 // Contains common inline helper functions used by the URL parsing routines. | 8 // Contains common inline helper functions used by the URL parsing routines. |
9 | 9 |
10 #include "url/url_parse.h" | 10 #include "url/third_party/mozilla/url_parse.h" |
11 | 11 |
12 namespace url { | 12 namespace url { |
13 | 13 |
14 // We treat slashes and backslashes the same for IE compatability. | 14 // We treat slashes and backslashes the same for IE compatibility. |
15 inline bool IsURLSlash(base::char16 ch) { | 15 inline bool IsURLSlash(base::char16 ch) { |
16 return ch == '/' || ch == '\\'; | 16 return ch == '/' || ch == '\\'; |
17 } | 17 } |
18 | 18 |
19 // Returns true if we should trim this character from the URL because it is a | 19 // Returns true if we should trim this character from the URL because it is a |
20 // space or a control character. | 20 // space or a control character. |
21 inline bool ShouldTrimFromURL(base::char16 ch) { | 21 inline bool ShouldTrimFromURL(base::char16 ch) { |
22 return ch <= ' '; | 22 return ch <= ' '; |
23 } | 23 } |
24 | 24 |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
82 int after_scheme, | 82 int after_scheme, |
83 Parsed* parsed); | 83 Parsed* parsed); |
84 void ParseAfterScheme(const base::char16* spec, | 84 void ParseAfterScheme(const base::char16* spec, |
85 int spec_len, | 85 int spec_len, |
86 int after_scheme, | 86 int after_scheme, |
87 Parsed* parsed); | 87 Parsed* parsed); |
88 | 88 |
89 } // namespace url | 89 } // namespace url |
90 | 90 |
91 #endif // URL_URL_PARSE_INTERNAL_H_ | 91 #endif // URL_URL_PARSE_INTERNAL_H_ |
OLD | NEW |