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

Side by Side Diff: third_party/WebKit/Source/platform/weborigin/KURL.h

Issue 2148423003: Use StringView for equalIgnoringCase. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: DCHECK is silly. Created 4 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2011, 2012 Apple Inc. All r ights reserved. 2 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2011, 2012 Apple Inc. All r ights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 159 matching lines...) Expand 10 before | Expand all | Expand 10 after
170 PLATFORM_EXPORT friend bool equalIgnoringFragmentIdentifier(const KURL&, con st KURL&); 170 PLATFORM_EXPORT friend bool equalIgnoringFragmentIdentifier(const KURL&, con st KURL&);
171 171
172 unsigned hostStart() const; 172 unsigned hostStart() const;
173 unsigned hostEnd() const; 173 unsigned hostEnd() const;
174 174
175 unsigned pathStart() const; 175 unsigned pathStart() const;
176 unsigned pathEnd() const; 176 unsigned pathEnd() const;
177 unsigned pathAfterLastSlash() const; 177 unsigned pathAfterLastSlash() const;
178 178
179 operator const String&() const { return getString(); } 179 operator const String&() const { return getString(); }
180 operator StringView() const { return StringView(getString()); }
180 181
181 const url::Parsed& parsed() const { return m_parsed; } 182 const url::Parsed& parsed() const { return m_parsed; }
182 183
183 const KURL* innerURL() const { return m_innerURL.get(); } 184 const KURL* innerURL() const { return m_innerURL.get(); }
184 185
185 bool isSafeToSendToAnotherThread() const; 186 bool isSafeToSendToAnotherThread() const;
186 187
187 private: 188 private:
188 void init(const KURL& base, const String& relative, const WTF::TextEncoding* queryEncoding); 189 void init(const KURL& base, const String& relative, const WTF::TextEncoding* queryEncoding);
189 190
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
272 namespace WTF { 273 namespace WTF {
273 274
274 // KURLHash is the default hash for String 275 // KURLHash is the default hash for String
275 template<> struct DefaultHash<blink::KURL> { 276 template<> struct DefaultHash<blink::KURL> {
276 typedef blink::KURLHash Hash; 277 typedef blink::KURLHash Hash;
277 }; 278 };
278 279
279 } // namespace WTF 280 } // namespace WTF
280 281
281 #endif // KURL_h 282 #endif // KURL_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698