From 275e260a6cd4a8e506ba974feb85ebcd926c1739 Mon Sep 17 00:00:00 2001 From: Ryan Harrison Date: Mon, 18 Sep 2017 14:23:18 -0400 Subject: Convert string class names Automated using git grep & sed. Replace StringC classes with StringView classes. Remove the CFX_ prefix and put string classes in fxcrt namespace. Change AsStringC() to AsStringView(). Rename tests from TEST(fxcrt, *String*Foo) to TEST(*String*, Foo). Couple of tests needed to have their names regularlized. BUG=pdfium:894 Change-Id: I7ca038685c8d803795f3ed02545124f7a224c83d Reviewed-on: https://pdfium-review.googlesource.com/14151 Reviewed-by: Tom Sepez Commit-Queue: Ryan Harrison --- fxjs/cfxjse_value.h | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'fxjs/cfxjse_value.h') diff --git a/fxjs/cfxjse_value.h b/fxjs/cfxjse_value.h index 31b751da1e..f506857965 100644 --- a/fxjs/cfxjse_value.h +++ b/fxjs/cfxjse_value.h @@ -38,9 +38,9 @@ class CFXJSE_Value { float ToFloat() const; double ToDouble() const; int32_t ToInteger() const; - CFX_ByteString ToString() const; - CFX_WideString ToWideString() const { - return CFX_WideString::FromUTF8(ToString().AsStringC()); + ByteString ToString() const; + WideString ToWideString() const { + return WideString::FromUTF8(ToString().AsStringView()); } CFXJSE_HostObject* ToHostObject(CFXJSE_Class* lpClass) const; @@ -49,7 +49,7 @@ class CFXJSE_Value { void SetBoolean(bool bBoolean); void SetInteger(int32_t nInteger); void SetDouble(double dDouble); - void SetString(const CFX_ByteStringC& szString); + void SetString(const ByteStringView& szString); void SetFloat(float fFloat); void SetJSObject(); @@ -58,16 +58,16 @@ class CFXJSE_Value { void SetArray(const std::vector>& values); void SetDate(double dDouble); - bool GetObjectProperty(const CFX_ByteStringC& szPropName, + bool GetObjectProperty(const ByteStringView& szPropName, CFXJSE_Value* lpPropValue); - bool SetObjectProperty(const CFX_ByteStringC& szPropName, + bool SetObjectProperty(const ByteStringView& szPropName, CFXJSE_Value* lpPropValue); bool GetObjectPropertyByIdx(uint32_t uPropIdx, CFXJSE_Value* lpPropValue); bool SetObjectProperty(uint32_t uPropIdx, CFXJSE_Value* lpPropValue); - bool DeleteObjectProperty(const CFX_ByteStringC& szPropName); - bool HasObjectOwnProperty(const CFX_ByteStringC& szPropName, + bool DeleteObjectProperty(const ByteStringView& szPropName); + bool HasObjectOwnProperty(const ByteStringView& szPropName, bool bUseTypeGetter); - bool SetObjectOwnProperty(const CFX_ByteStringC& szPropName, + bool SetObjectOwnProperty(const ByteStringView& szPropName, CFXJSE_Value* lpPropValue); bool SetFunctionBind(CFXJSE_Value* lpOldFunction, CFXJSE_Value* lpNewThis); bool Call(CFXJSE_Value* lpReceiver, -- cgit v1.2.3