| OLD | NEW |
| (Empty) |
| 1 // Copyright 2014 PDFium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | |
| 6 | |
| 7 #ifndef XFA_SRC_FXFA_FM2JS_XFA_FMPARSE_H_ | |
| 8 #define XFA_SRC_FXFA_FM2JS_XFA_FMPARSE_H_ | |
| 9 | |
| 10 #include <memory> | |
| 11 | |
| 12 #include "xfa/src/fxfa/fm2js/xfa_expression.h" | |
| 13 #include "xfa/src/fxfa/fm2js/xfa_lexer.h" | |
| 14 | |
| 15 class CXFA_FMParse { | |
| 16 public: | |
| 17 CXFA_FMParse(); | |
| 18 int32_t Init(const CFX_WideStringC& wsFormcalc, CXFA_FMErrorInfo* pErrorInfo); | |
| 19 void NextToken(); | |
| 20 void Check(XFA_FM_TOKEN op); | |
| 21 void Error(FX_DWORD lineNum, XFA_FM_ERRMSG msg, ...); | |
| 22 CFX_PtrArray* ParseTopExpression(); | |
| 23 CXFA_FMExpression* ParseFunction(); | |
| 24 CXFA_FMExpression* ParseExpression(); | |
| 25 CXFA_FMExpression* ParseVarExpression(); | |
| 26 CXFA_FMExpression* ParseExpExpression(); | |
| 27 CXFA_FMExpression* ParseBlockExpression(); | |
| 28 CXFA_FMExpression* ParseIfExpression(); | |
| 29 CXFA_FMExpression* ParseWhileExpression(); | |
| 30 CXFA_FMExpression* ParseForExpression(); | |
| 31 CXFA_FMExpression* ParseForeachExpression(); | |
| 32 CXFA_FMExpression* ParseDoExpression(); | |
| 33 CXFA_FMSimpleExpression* ParseParenExpression(); | |
| 34 CXFA_FMSimpleExpression* ParseSimpleExpression(); | |
| 35 CXFA_FMSimpleExpression* ParseSubassignmentInForExpression(); | |
| 36 CXFA_FMSimpleExpression* ParseLogicalOrExpression(); | |
| 37 CXFA_FMSimpleExpression* ParseLogicalAndExpression(); | |
| 38 CXFA_FMSimpleExpression* ParseEqualityExpression(); | |
| 39 CXFA_FMSimpleExpression* ParseRelationalExpression(); | |
| 40 CXFA_FMSimpleExpression* ParseAddtiveExpression(); | |
| 41 CXFA_FMSimpleExpression* ParseMultiplicativeExpression(); | |
| 42 CXFA_FMSimpleExpression* ParseUnaryExpression(); | |
| 43 CXFA_FMSimpleExpression* ParsePrimaryExpression(); | |
| 44 CXFA_FMSimpleExpression* ParsePostExpression(CXFA_FMSimpleExpression* e); | |
| 45 CXFA_FMSimpleExpression* ParseIndexExpression(); | |
| 46 | |
| 47 private: | |
| 48 std::unique_ptr<CXFA_FMLexer> m_lexer; | |
| 49 CXFA_FMToken* m_pToken; | |
| 50 CXFA_FMErrorInfo* m_pErrorInfo; | |
| 51 }; | |
| 52 | |
| 53 #endif // XFA_SRC_FXFA_FM2JS_XFA_FMPARSE_H_ | |
| OLD | NEW |