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

Side by Side Diff: ios/web/public/string_util.h

Issue 1544743002: Switch to standard integer types in ios/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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
« no previous file with comments | « ios/web/public/referrer_util_unittest.cc ('k') | ios/web/public/test/http_server.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 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 IOS_WEB_PUBLIC_STRING_UTIL_H_ 5 #ifndef IOS_WEB_PUBLIC_STRING_UTIL_H_
6 #define IOS_WEB_PUBLIC_STRING_UTIL_H_ 6 #define IOS_WEB_PUBLIC_STRING_UTIL_H_
7 7
8 #include <stddef.h>
9
8 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
9 11
10 namespace web { 12 namespace web {
11 13
12 // Truncates |contents| to |length|. 14 // Truncates |contents| to |length|.
13 // Returns a string terminated at the last space to ensure no words are 15 // Returns a string terminated at the last space to ensure no words are
14 // clipped. 16 // clipped.
15 // Note: This function uses spaces as word boundaries and may not handle all 17 // Note: This function uses spaces as word boundaries and may not handle all
16 // languages correctly. 18 // languages correctly.
17 base::string16 GetStringByClippingLastWord(const base::string16& contents, 19 base::string16 GetStringByClippingLastWord(const base::string16& contents,
18 size_t length); 20 size_t length);
19 21
20 } // namespace web 22 } // namespace web
21 23
22 #endif // IOS_WEB_PUBLIC_STRING_UTIL_H_ 24 #endif // IOS_WEB_PUBLIC_STRING_UTIL_H_
OLDNEW
« no previous file with comments | « ios/web/public/referrer_util_unittest.cc ('k') | ios/web/public/test/http_server.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698