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

Side by Side Diff: Source/wtf/text/AtomicString.h

Issue 22572005: Remove all uses of the ASCIILiteral class. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rm it from wtf Created 7 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « Source/wtf/tests/WTFString.cpp ('k') | Source/wtf/text/StringConcatenate.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2004, 2005, 2006, 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2004, 2005, 2006, 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * This library is free software; you can redistribute it and/or 4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public 5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either 6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version. 7 * version 2 of the License, or (at your option) any later version.
8 * 8 *
9 * This library is distributed in the hope that it will be useful, 9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of 10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
153 // AtomicString::fromUTF8 will return a null string if 153 // AtomicString::fromUTF8 will return a null string if
154 // the input data contains invalid UTF-8 sequences. 154 // the input data contains invalid UTF-8 sequences.
155 static AtomicString fromUTF8(const char*, size_t); 155 static AtomicString fromUTF8(const char*, size_t);
156 static AtomicString fromUTF8(const char*); 156 static AtomicString fromUTF8(const char*);
157 157
158 #ifndef NDEBUG 158 #ifndef NDEBUG
159 void show() const; 159 void show() const;
160 #endif 160 #endif
161 161
162 private: 162 private:
163 // The explicit constructors with AtomicString::ConstructFromLiteral must be used for literals.
164 AtomicString(ASCIILiteral);
165
166 String m_string; 163 String m_string;
167 164
168 static PassRefPtr<StringImpl> add(const LChar*); 165 static PassRefPtr<StringImpl> add(const LChar*);
169 ALWAYS_INLINE static PassRefPtr<StringImpl> add(const char* s) { return add( reinterpret_cast<const LChar*>(s)); }; 166 ALWAYS_INLINE static PassRefPtr<StringImpl> add(const char* s) { return add( reinterpret_cast<const LChar*>(s)); };
170 static PassRefPtr<StringImpl> add(const LChar*, unsigned length); 167 static PassRefPtr<StringImpl> add(const LChar*, unsigned length);
171 static PassRefPtr<StringImpl> add(const UChar*, unsigned length); 168 static PassRefPtr<StringImpl> add(const UChar*, unsigned length);
172 ALWAYS_INLINE static PassRefPtr<StringImpl> add(const char* s, unsigned leng th) { return add(reinterpret_cast<const LChar*>(s), length); }; 169 ALWAYS_INLINE static PassRefPtr<StringImpl> add(const char* s, unsigned leng th) { return add(reinterpret_cast<const LChar*>(s), length); };
173 static PassRefPtr<StringImpl> add(const UChar*, unsigned length, unsigned ex istingHash); 170 static PassRefPtr<StringImpl> add(const UChar*, unsigned length, unsigned ex istingHash);
174 static PassRefPtr<StringImpl> add(const UChar*); 171 static PassRefPtr<StringImpl> add(const UChar*);
175 static PassRefPtr<StringImpl> add(StringImpl*, unsigned offset, unsigned len gth); 172 static PassRefPtr<StringImpl> add(StringImpl*, unsigned offset, unsigned len gth);
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 using WTF::textAtom; 257 using WTF::textAtom;
261 using WTF::commentAtom; 258 using WTF::commentAtom;
262 using WTF::starAtom; 259 using WTF::starAtom;
263 using WTF::xmlAtom; 260 using WTF::xmlAtom;
264 using WTF::xmlnsAtom; 261 using WTF::xmlnsAtom;
265 using WTF::xlinkAtom; 262 using WTF::xlinkAtom;
266 #endif 263 #endif
267 264
268 #include "wtf/text/StringConcatenate.h" 265 #include "wtf/text/StringConcatenate.h"
269 #endif // AtomicString_h 266 #endif // AtomicString_h
OLDNEW
« no previous file with comments | « Source/wtf/tests/WTFString.cpp ('k') | Source/wtf/text/StringConcatenate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698