From 2efb11c89ee200473f5675ba3d3a946d5606e813 Mon Sep 17 00:00:00 2001 From: Dan Sinclair Date: Thu, 12 Apr 2018 13:21:48 +0000 Subject: Retrieve the XML tree in the DocumentParser This CL changes the document parser to store the parsed XML tree. That way we no longer need to store the pointer to the CXFA_SimpleParser in the CXFA_DocumentParser. Change-Id: I9272150e73613411cb1bb59c3cf77c7af6cc799d Reviewed-on: https://pdfium-review.googlesource.com/30211 Reviewed-by: Henrique Nakashima Commit-Queue: dsinclair --- xfa/fxfa/parser/cxfa_simple_parser.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'xfa/fxfa/parser/cxfa_simple_parser.h') diff --git a/xfa/fxfa/parser/cxfa_simple_parser.h b/xfa/fxfa/parser/cxfa_simple_parser.h index 61edf8e8e6..157983fe8e 100644 --- a/xfa/fxfa/parser/cxfa_simple_parser.h +++ b/xfa/fxfa/parser/cxfa_simple_parser.h @@ -8,14 +8,15 @@ #define XFA_FXFA_PARSER_CXFA_SIMPLE_PARSER_H_ #include +#include +#include "core/fxcrt/xml/cfx_xmlnode.h" #include "xfa/fxfa/fxfa_basic.h" class CXFA_Document; class CXFA_Node; class CFX_XMLDoc; class CFX_XMLInstruction; -class CFX_XMLNode; class IFX_SeekableStream; class CFX_SeekableStreamProxy; @@ -30,6 +31,8 @@ class CXFA_SimpleParser { CFX_XMLNode* ParseXMLData(const ByteString& wsXML); void ConstructXFANode(CXFA_Node* pXFANode, CFX_XMLNode* pXMLNode); + + std::unique_ptr GetXMLRoot() { return std::move(m_pNodeTree); } CXFA_Node* GetRootNode() const; // Called later for the ctor with no parameters. -- cgit v1.2.3