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 --- core/fpdfapi/parser/cpdf_syntax_parser.h | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'core/fpdfapi/parser/cpdf_syntax_parser.h') diff --git a/core/fpdfapi/parser/cpdf_syntax_parser.h b/core/fpdfapi/parser/cpdf_syntax_parser.h index 179058edf8..4e28c2fb92 100644 --- a/core/fpdfapi/parser/cpdf_syntax_parser.h +++ b/core/fpdfapi/parser/cpdf_syntax_parser.h @@ -26,7 +26,7 @@ class CPDF_SyntaxParser { enum class ParseType { kStrict, kLoose }; CPDF_SyntaxParser(); - explicit CPDF_SyntaxParser(const CFX_WeakPtr& pPool); + explicit CPDF_SyntaxParser(const CFX_WeakPtr& pPool); ~CPDF_SyntaxParser(); void InitParser(const CFX_RetainPtr& pFileAccess, @@ -56,16 +56,16 @@ class CPDF_SyntaxParser { bool bDecrypt, ParseType parse_type); - CFX_ByteString GetKeyword(); + ByteString GetKeyword(); void ToNextLine(); void ToNextWord(); - bool BackwardsSearchToWord(const CFX_ByteStringC& word, FX_FILESIZE limit); - FX_FILESIZE FindTag(const CFX_ByteStringC& tag, FX_FILESIZE limit); + bool BackwardsSearchToWord(const ByteStringView& word, FX_FILESIZE limit); + FX_FILESIZE FindTag(const ByteStringView& tag, FX_FILESIZE limit); void SetEncrypt(const CFX_RetainPtr& pCryptoHandler); bool ReadBlock(uint8_t* pBuf, uint32_t size); bool GetCharAt(FX_FILESIZE pos, uint8_t& ch); - CFX_ByteString GetNextWord(bool* bIsNumber); - CFX_ByteString PeekNextWord(bool* bIsNumber); + ByteString GetNextWord(bool* bIsNumber); + ByteString PeekNextWord(bool* bIsNumber); CFX_RetainPtr GetFileAccess() const; @@ -88,11 +88,11 @@ class CPDF_SyntaxParser { void GetNextWordInternal(bool* bIsNumber); bool IsWholeWord(FX_FILESIZE startpos, FX_FILESIZE limit, - const CFX_ByteStringC& tag, + const ByteStringView& tag, bool checkKeyword); - CFX_ByteString ReadString(); - CFX_ByteString ReadHexString(); + ByteString ReadString(); + ByteString ReadHexString(); unsigned int ReadEOLMarkers(FX_FILESIZE pos); std::unique_ptr ReadStream( std::unique_ptr pDict, @@ -122,7 +122,7 @@ class CPDF_SyntaxParser { CFX_RetainPtr m_pCryptoHandler; uint8_t m_WordBuffer[257]; uint32_t m_WordSize; - CFX_WeakPtr m_pPool; + CFX_WeakPtr m_pPool; }; #endif // CORE_FPDFAPI_PARSER_CPDF_SYNTAX_PARSER_H_ -- cgit v1.2.3