diff options
author | tony@chromium.org <tony@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-09-29 21:32:01 +0000 |
---|---|---|
committer | tony@chromium.org <tony@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-09-29 21:32:01 +0000 |
commit | e4dad5bd72ddd563b84eede80cf2b414ea688b2c (patch) | |
tree | 24aa18551de46887173b800c33e8882bf31e712d /base/string_util.h | |
parent | 69877c29ce86be61d54007e5b515415fb05d78f8 (diff) | |
download | chromium_src-e4dad5bd72ddd563b84eede80cf2b414ea688b2c.zip chromium_src-e4dad5bd72ddd563b84eede80cf2b414ea688b2c.tar.gz chromium_src-e4dad5bd72ddd563b84eede80cf2b414ea688b2c.tar.bz2 |
Add a version of ReplaceStringPlaceholders that operates on std::string
instead of string16.
BUG=none
TEST=base unit tests
Original patch by avd@google.com at:
http://codereview.chromium.org/245046
Review URL: http://codereview.chromium.org/242061
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@27532 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/string_util.h')
-rw-r--r-- | base/string_util.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/base/string_util.h b/base/string_util.h index 9143346..64c1f60 100644 --- a/base/string_util.h +++ b/base/string_util.h @@ -607,6 +607,10 @@ string16 ReplaceStringPlaceholders(const string16& format_string, const std::vector<string16>& subst, std::vector<size_t>* offsets); +std::string ReplaceStringPlaceholders(const std::string& format_string, + const std::vector<std::string>& subst, + std::vector<size_t>* offsets); + // Single-string shortcut for ReplaceStringHolders. string16 ReplaceStringPlaceholders(const string16& format_string, const string16& a, |