Class ExceptionConvertor

java.lang.Object
com.espertech.esper.compiler.internal.parse.ExceptionConvertor

public class ExceptionConvertor extends Object
Converts recognition exceptions.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected static final String
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static com.espertech.esper.common.internal.collection.UniformPair<String>
    convert(org.antlr.v4.runtime.RecognitionException e, String expression, boolean addPleaseCheck, EsperEPL2GrammarParser parser)
    Converts from a syntax error to a nice exception.
    static com.espertech.esper.common.client.PropertyAccessException
    convertProperty(org.antlr.v4.runtime.RecognitionException e, String expression, boolean addPleaseCheck, EsperEPL2GrammarParser parser)
    Converts from a syntax error to a nice property exception.
    static com.espertech.esper.common.internal.compile.stage2.StatementSpecCompileSyntaxException
    convertStatement(org.antlr.v4.runtime.RecognitionException e, String expression, boolean addPleaseCheck, EsperEPL2GrammarParser parser)
    Converts from a syntax error to a nice statement exception.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

  • Constructor Details

    • ExceptionConvertor

      public ExceptionConvertor()
  • Method Details

    • convertStatement

      public static com.espertech.esper.common.internal.compile.stage2.StatementSpecCompileSyntaxException convertStatement(org.antlr.v4.runtime.RecognitionException e, String expression, boolean addPleaseCheck, EsperEPL2GrammarParser parser)
      Converts from a syntax error to a nice statement exception.
      Parameters:
      e - is the syntax error
      expression - is the expression text
      parser - the parser that parsed the expression
      addPleaseCheck - indicates to add "please check" paraphrases
      Returns:
      syntax exception
    • convertProperty

      public static com.espertech.esper.common.client.PropertyAccessException convertProperty(org.antlr.v4.runtime.RecognitionException e, String expression, boolean addPleaseCheck, EsperEPL2GrammarParser parser)
      Converts from a syntax error to a nice property exception.
      Parameters:
      e - is the syntax error
      expression - is the expression text
      parser - the parser that parsed the expression
      addPleaseCheck - indicates to add "please check" paraphrases
      Returns:
      syntax exception
    • convert

      public static com.espertech.esper.common.internal.collection.UniformPair<String> convert(org.antlr.v4.runtime.RecognitionException e, String expression, boolean addPleaseCheck, EsperEPL2GrammarParser parser)
      Converts from a syntax error to a nice exception.
      Parameters:
      e - is the syntax error
      expression - is the expression text
      parser - the parser that parsed the expression
      addPleaseCheck - indicates to add "please check" paraphrases
      Returns:
      syntax exception