summaryrefslogtreecommitdiff
path: root/core/fxcrt/bytestring.h
diff options
context:
space:
mode:
authorDan Sinclair <dsinclair@chromium.org>2017-11-16 22:08:07 +0000
committerChromium commit bot <commit-bot@chromium.org>2017-11-16 22:08:07 +0000
commit1c4735aed9442a8e442214a23a3df94bd8fc99b5 (patch)
tree37264efcc3a1d90e3a9f05384d283923c828242f /core/fxcrt/bytestring.h
parent3f1c832dda209cf6682bb75316c07d71332fe6c3 (diff)
downloadpdfium-1c4735aed9442a8e442214a23a3df94bd8fc99b5.tar.xz
Convert ByteString::{Format|FormatV} to static methods
This CL moves the Format and FormatV methods of ByteString to be static. Bug: pdfium:934 Change-Id: I9c30455a789aff9f619b9d5bf89c0712644f2d9a Reviewed-on: https://pdfium-review.googlesource.com/18650 Commit-Queue: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'core/fxcrt/bytestring.h')
-rw-r--r--core/fxcrt/bytestring.h11
1 files changed, 5 insertions, 6 deletions
diff --git a/core/fxcrt/bytestring.h b/core/fxcrt/bytestring.h
index f534b08b8a..1acece3aee 100644
--- a/core/fxcrt/bytestring.h
+++ b/core/fxcrt/bytestring.h
@@ -32,6 +32,11 @@ class ByteString {
using const_iterator = const CharType*;
using const_reverse_iterator = std::reverse_iterator<const_iterator>;
+ static ByteString FormatInteger(int i);
+ static ByteString FormatFloat(float f);
+ static ByteString Format(const char* lpszFormat, ...);
+ static ByteString FormatV(const char* lpszFormat, va_list argList);
+
ByteString();
ByteString(const ByteString& other);
ByteString(ByteString&& other) noexcept;
@@ -138,9 +143,6 @@ class ByteString {
size_t InsertAtBack(char ch) { return Insert(GetLength(), ch); }
size_t Delete(size_t index, size_t count = 1);
- void Format(const char* lpszFormat, ...);
- void FormatV(const char* lpszFormat, va_list argList);
-
void Reserve(size_t len);
char* GetBuffer(size_t len);
void ReleaseBuffer(size_t len);
@@ -181,9 +183,6 @@ class ByteString {
uint32_t GetID() const { return AsStringView().GetID(); }
- static ByteString FormatInteger(int i);
- static ByteString FormatFloat(float f);
-
protected:
using StringData = StringDataTemplate<char>;