OLD | NEW |
1 // Copyright 2016 PDFium Authors. All rights reserved. | 1 // Copyright 2016 PDFium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
6 | 6 |
7 #ifndef XFA_FXFA_PARSER_CXFA_XML_PARSER_H_ | 7 #ifndef XFA_FXFA_PARSER_CXFA_XML_PARSER_H_ |
8 #define XFA_FXFA_PARSER_CXFA_XML_PARSER_H_ | 8 #define XFA_FXFA_PARSER_CXFA_XML_PARSER_H_ |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
11 | 11 |
12 #include "xfa/fde/xml/fde_xml_imp.h" | 12 #include "xfa/fde/xml/fde_xml_imp.h" |
13 | 13 |
14 class IFGAS_Stream; | 14 class IFGAS_Stream; |
15 class IFX_Pause; | 15 class IFX_Pause; |
16 | 16 |
17 class CXFA_XMLParser : public CFDE_XMLParser { | 17 class CXFA_XMLParser : public IFDE_XMLParser { |
18 public: | 18 public: |
19 CXFA_XMLParser(CFDE_XMLNode* pRoot, | 19 CXFA_XMLParser(CFDE_XMLNode* pRoot, |
20 const CFX_RetainPtr<IFGAS_Stream>& pStream); | 20 const CFX_RetainPtr<IFGAS_Stream>& pStream); |
21 ~CXFA_XMLParser() override; | 21 ~CXFA_XMLParser() override; |
22 | 22 |
23 // CFDE_XMLParser | 23 // IFDE_XMLParser |
24 void Release() override; | |
25 int32_t DoParser(IFX_Pause* pPause) override; | 24 int32_t DoParser(IFX_Pause* pPause) override; |
26 | 25 |
27 FX_FILESIZE m_nStart[2]; | 26 FX_FILESIZE m_nStart[2]; |
28 size_t m_nSize[2]; | 27 size_t m_nSize[2]; |
29 FX_FILESIZE m_nElementStart; | 28 FX_FILESIZE m_nElementStart; |
30 uint16_t m_dwCheckStatus; | 29 uint16_t m_dwCheckStatus; |
31 uint16_t m_dwCurrentCheckStatus; | 30 uint16_t m_dwCurrentCheckStatus; |
32 | 31 |
33 protected: | 32 protected: |
34 CFDE_XMLNode* m_pRoot; | 33 CFDE_XMLNode* m_pRoot; |
35 CFX_RetainPtr<IFGAS_Stream> m_pStream; | 34 CFX_RetainPtr<IFGAS_Stream> m_pStream; |
36 std::unique_ptr<CFDE_XMLSyntaxParser, ReleaseDeleter<CFDE_XMLSyntaxParser>> | 35 std::unique_ptr<CFDE_XMLSyntaxParser, ReleaseDeleter<CFDE_XMLSyntaxParser>> |
37 m_pParser; | 36 m_pParser; |
38 CFDE_XMLNode* m_pParent; | 37 CFDE_XMLNode* m_pParent; |
39 CFDE_XMLNode* m_pChild; | 38 CFDE_XMLNode* m_pChild; |
40 CFX_StackTemplate<CFDE_XMLNode*> m_NodeStack; | 39 CFX_StackTemplate<CFDE_XMLNode*> m_NodeStack; |
41 CFX_WideString m_ws1; | 40 CFX_WideString m_ws1; |
42 CFX_WideString m_ws2; | 41 CFX_WideString m_ws2; |
43 FDE_XmlSyntaxResult m_syntaxParserResult; | 42 FDE_XmlSyntaxResult m_syntaxParserResult; |
44 }; | 43 }; |
45 | 44 |
46 #endif // XFA_FXFA_PARSER_CXFA_XML_PARSER_H_ | 45 #endif // XFA_FXFA_PARSER_CXFA_XML_PARSER_H_ |
OLD | NEW |