Class ExpressionCompiler

java.lang.Object
org.mvel2.compiler.AbstractParser
org.mvel2.compiler.ExpressionCompiler
All Implemented Interfaces:
Serializable, Parser

public class ExpressionCompiler extends AbstractParser
This is the main MVEL compiler.
See Also:
  • Field Details

    • returnType

      private Class returnType
    • verifyOnly

      private boolean verifyOnly
    • verifying

      private boolean verifying
    • secondPassOptimization

      private boolean secondPassOptimization
  • Constructor Details

    • ExpressionCompiler

      public ExpressionCompiler(String expression)
    • ExpressionCompiler

      public ExpressionCompiler(String expression, boolean verifying)
    • ExpressionCompiler

      public ExpressionCompiler(char[] expression)
    • ExpressionCompiler

      public ExpressionCompiler(String expression, ParserContext ctx)
    • ExpressionCompiler

      public ExpressionCompiler(char[] expression, int start, int offset)
    • ExpressionCompiler

      public ExpressionCompiler(String expression, int start, int offset, ParserContext ctx)
    • ExpressionCompiler

      public ExpressionCompiler(char[] expression, int start, int offset, ParserContext ctx)
    • ExpressionCompiler

      public ExpressionCompiler(char[] expression, ParserContext ctx)
  • Method Details

    • compile

      public CompiledExpression compile()
    • _compile

      public CompiledExpression _compile()
      Initiate an in-context compileShared. This method should really only be called by the internal API.
      Returns:
      compiled expression object
    • getStackValueResult

      private Object getStackValueResult()
    • compileReduce

      private boolean compileReduce(int opCode, ASTLinkedList astBuild)
    • isBooleanOperator

      private static boolean isBooleanOperator(int operator)
    • verify

      protected ASTNode verify(ParserContext pCtx, ASTNode tk)
    • isVerifying

      public boolean isVerifying()
    • setVerifying

      public void setVerifying(boolean verifying)
    • isVerifyOnly

      public boolean isVerifyOnly()
    • setVerifyOnly

      public void setVerifyOnly(boolean verifyOnly)
    • getReturnType

      public Class getReturnType()
    • setReturnType

      public void setReturnType(Class returnType)
    • getParserContextState

      public ParserContext getParserContextState()
    • isLiteralOnly

      public boolean isLiteralOnly()