summaryrefslogtreecommitdiffstats
path: root/base/string_tokenizer.h
diff options
context:
space:
mode:
authorericroman@google.com <ericroman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-06 01:00:53 +0000
committerericroman@google.com <ericroman@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-09-06 01:00:53 +0000
commit036d87726035ac500ba35ab41fdc9ef6128f0e4f (patch)
tree48f2abffad974fd7599616cd2fa7888f2a5d7fe8 /base/string_tokenizer.h
parent9b323e40ae67692745459f68920f5dab61aaaed3 (diff)
downloadchromium_src-036d87726035ac500ba35ab41fdc9ef6128f0e4f.zip
chromium_src-036d87726035ac500ba35ab41fdc9ef6128f0e4f.tar.gz
chromium_src-036d87726035ac500ba35ab41fdc9ef6128f0e4f.tar.bz2
[new http] Normalize line continuations in response headers.
BUG=1272571 Review URL: http://codereview.chromium.org/458 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@1818 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/string_tokenizer.h')
-rw-r--r--base/string_tokenizer.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/base/string_tokenizer.h b/base/string_tokenizer.h
index 22d3628..27df4b3 100644
--- a/base/string_tokenizer.h
+++ b/base/string_tokenizer.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef BASE_STRING_TOKENIZER_H__
-#define BASE_STRING_TOKENIZER_H__
+#ifndef BASE_STRING_TOKENIZER_H_
+#define BASE_STRING_TOKENIZER_H_
#include <string>
@@ -74,10 +74,9 @@
// }
//
//
-template <class str>
+template <class str, class const_iterator>
class StringTokenizerT {
public:
- typedef typename str::const_iterator const_iterator;
typedef typename str::value_type char_type;
// Options that may be pass to set_options()
@@ -194,8 +193,11 @@ class StringTokenizerT {
bool token_is_delim_;
};
-typedef StringTokenizerT<std::string> StringTokenizer;
-typedef StringTokenizerT<std::wstring> WStringTokenizer;
+typedef StringTokenizerT<std::string, std::string::const_iterator>
+ StringTokenizer;
+typedef StringTokenizerT<std::wstring, std::wstring::const_iterator>
+ WStringTokenizer;
+typedef StringTokenizerT<std::string, const char*> CStringTokenizer;
-#endif // BASE_STRING_TOKENIZER_H__
+#endif // BASE_STRING_TOKENIZER_H_