diff options
author | tsepez <tsepez@chromium.org> | 2016-12-02 10:53:30 -0800 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2016-12-02 10:53:30 -0800 |
commit | 0527ec571a8842b84f5161dc67f8da439e65eb12 (patch) | |
tree | d645df1008a5dcd6ea3224080cfc6f7779706c68 /xfa/fde/xml | |
parent | 8b6a0a540563c6308fa03df34c90257e0bb65598 (diff) | |
download | pdfium-0527ec571a8842b84f5161dc67f8da439e65eb12.tar.xz |
Rename IFX_Stream to IFGAS_Stream.
It's a separate hierarchy unrelated to the IFX_*Stream classes.
Also rename CFX_Stream to CFGAS_Stream, and so forth.
Review-Url: https://codereview.chromium.org/2535723010
Diffstat (limited to 'xfa/fde/xml')
-rw-r--r-- | xfa/fde/xml/fde_xml_imp.cpp | 8 | ||||
-rw-r--r-- | xfa/fde/xml/fde_xml_imp.h | 12 | ||||
-rw-r--r-- | xfa/fde/xml/fde_xml_imp_unittest.cpp | 30 |
3 files changed, 25 insertions, 25 deletions
diff --git a/xfa/fde/xml/fde_xml_imp.cpp b/xfa/fde/xml/fde_xml_imp.cpp index cf145fdb65..1fbb1cdda7 100644 --- a/xfa/fde/xml/fde_xml_imp.cpp +++ b/xfa/fde/xml/fde_xml_imp.cpp @@ -394,7 +394,7 @@ CFDE_XMLNode* CFDE_XMLNode::Clone(bool bRecursive) { return nullptr; } -void CFDE_XMLNode::SaveXMLNode(IFX_Stream* pXMLStream) { +void CFDE_XMLNode::SaveXMLNode(IFGAS_Stream* pXMLStream) { CFDE_XMLNode* pNode = (CFDE_XMLNode*)this; switch (pNode->GetType()) { case FDE_XMLNODE_Instruction: { @@ -986,7 +986,7 @@ void CFDE_XMLDoc::CloseXML() { ReleaseParser(); } -void CFDE_XMLDoc::SaveXMLNode(IFX_Stream* pXMLStream, CFDE_XMLNode* pINode) { +void CFDE_XMLDoc::SaveXMLNode(IFGAS_Stream* pXMLStream, CFDE_XMLNode* pINode) { CFDE_XMLNode* pNode = (CFDE_XMLNode*)pINode; switch (pNode->GetType()) { case FDE_XMLNODE_Instruction: { @@ -1096,7 +1096,7 @@ void CFDE_XMLDoc::SaveXMLNode(IFX_Stream* pXMLStream, CFDE_XMLNode* pINode) { } } -void CFDE_XMLDoc::SaveXML(IFX_Stream* pXMLStream, bool bSaveBOM) { +void CFDE_XMLDoc::SaveXML(IFGAS_Stream* pXMLStream, bool bSaveBOM) { if (!pXMLStream || pXMLStream == m_pStream) { m_pStream->Seek(FX_STREAMSEEK_Begin, 0); pXMLStream = m_pStream; @@ -1288,7 +1288,7 @@ CFDE_XMLSyntaxParser::CFDE_XMLSyntaxParser() m_CurNode.eNodeType = FDE_XMLNODE_Unknown; } -void CFDE_XMLSyntaxParser::Init(IFX_Stream* pStream, +void CFDE_XMLSyntaxParser::Init(IFGAS_Stream* pStream, int32_t iXMLPlaneSize, int32_t iTextDataSize) { ASSERT(!m_pStream && !m_pBuffer); diff --git a/xfa/fde/xml/fde_xml_imp.h b/xfa/fde/xml/fde_xml_imp.h index 1119ef2ff5..924f958b86 100644 --- a/xfa/fde/xml/fde_xml_imp.h +++ b/xfa/fde/xml/fde_xml_imp.h @@ -63,7 +63,7 @@ class CFDE_XMLNode : public CFX_Target { bool InsertNodeItem(CFDE_XMLNode::NodeItem eItem, CFDE_XMLNode* pNode); CFDE_XMLNode* RemoveNodeItem(CFDE_XMLNode::NodeItem eItem); - void SaveXMLNode(IFX_Stream* pXMLStream); + void SaveXMLNode(IFGAS_Stream* pXMLStream); CFDE_XMLNode* m_pParent; CFDE_XMLNode* m_pChild; @@ -197,14 +197,14 @@ class CFDE_XMLDoc : public CFX_Target { int32_t DoLoad(IFX_Pause* pPause = nullptr); void CloseXML(); CFDE_XMLNode* GetRoot() const { return m_pRoot; } - void SaveXML(IFX_Stream* pXMLStream = nullptr, bool bSaveBOM = true); - void SaveXMLNode(IFX_Stream* pXMLStream, CFDE_XMLNode* pNode); + void SaveXML(IFGAS_Stream* pXMLStream = nullptr, bool bSaveBOM = true); + void SaveXMLNode(IFGAS_Stream* pXMLStream, CFDE_XMLNode* pNode); protected: void Reset(bool bInitRoot); void ReleaseParser(); - IFX_Stream* m_pStream; + IFGAS_Stream* m_pStream; int32_t m_iStatus; CFDE_XMLNode* m_pRoot; CFDE_XMLSyntaxParser* m_pSyntaxParser; @@ -261,7 +261,7 @@ class CFDE_XMLSyntaxParser : public CFX_Target { ~CFDE_XMLSyntaxParser() override; void Release() { delete this; } - void Init(IFX_Stream* pStream, + void Init(IFGAS_Stream* pStream, int32_t iXMLPlaneSize, int32_t iTextDataSize = 256); @@ -320,7 +320,7 @@ class CFDE_XMLSyntaxParser : public CFX_Target { void ParseTextChar(FX_WCHAR ch); - IFX_Stream* m_pStream; + IFGAS_Stream* m_pStream; int32_t m_iXMLPlaneSize; int32_t m_iCurrentPos; int32_t m_iCurrentNodeNum; diff --git a/xfa/fde/xml/fde_xml_imp_unittest.cpp b/xfa/fde/xml/fde_xml_imp_unittest.cpp index e5bcb0acb2..553afffd86 100644 --- a/xfa/fde/xml/fde_xml_imp_unittest.cpp +++ b/xfa/fde/xml/fde_xml_imp_unittest.cpp @@ -26,7 +26,7 @@ TEST(CFDE_XMLSyntaxParser, CData) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -84,7 +84,7 @@ TEST(CFDE_XMLSyntaxParser, CDataWithInnerScript) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -131,7 +131,7 @@ TEST(CFDE_XMLSyntaxParser, ArrowBangArrow) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -174,7 +174,7 @@ TEST(CFDE_XMLSyntaxParser, ArrowBangBracketArrow) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -211,7 +211,7 @@ TEST(CFDE_XMLSyntaxParser, IncompleteCData) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -248,7 +248,7 @@ TEST(CFDE_XMLSyntaxParser, UnClosedCData) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -285,7 +285,7 @@ TEST(CFDE_XMLSyntaxParser, EmptyCData) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -332,7 +332,7 @@ TEST(CFDE_XMLSyntaxParser, Comment) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -375,7 +375,7 @@ TEST(CFDE_XMLSyntaxParser, IncorrectCommentStart) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -418,7 +418,7 @@ TEST(CFDE_XMLSyntaxParser, CommentEmpty) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -461,7 +461,7 @@ TEST(CFDE_XMLSyntaxParser, CommentThreeDash) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -496,7 +496,7 @@ TEST(CFDE_XMLSyntaxParser, CommentTwoDash) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -535,7 +535,7 @@ TEST(CFDE_XMLSyntaxParser, Entities) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -575,7 +575,7 @@ TEST(CFDE_XMLSyntaxParser, EntityOverflowHex) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); @@ -615,7 +615,7 @@ TEST(CFDE_XMLSyntaxParser, EntityOverflowDecimal) { // We * sizeof(FX_WCHAR) because we pass in the uint8_t, not the FX_WCHAR. size_t len = FXSYS_wcslen(input) * sizeof(FX_WCHAR); - std::unique_ptr<IFX_Stream> stream(IFX_Stream::CreateStream( + std::unique_ptr<IFGAS_Stream> stream(IFGAS_Stream::CreateStream( reinterpret_cast<uint8_t*>(const_cast<FX_WCHAR*>(input)), len, 0)); CFDE_XMLSyntaxParser parser; parser.Init(stream.get(), 256); |