Interface TAFParseDiagnosticListener

  • All Known Implementing Classes:
    PrintStreamDiagnosticListener

    public interface TAFParseDiagnosticListener
    Diagnostic listener for non-fatal errors and warnings during parsing of a TAF file. The parser will usually recover from these errors and produce a valid automaton anyway. Fatal errors are not reported to a diagnostic listener, but instead a TAFFormatException is thrown.
    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void error​(int line, int col, String msgFmt, Object... args)
      Called when a non-fatal error is encountered during parsing.
      void warning​(int line, int col, String msgFmt, Object... args)
      Called when a warning is raised during parsing.
    • Method Detail

      • error

        void error​(int line,
                   int col,
                   String msgFmt,
                   Object... args)
        Called when a non-fatal error is encountered during parsing.

        A non-fatal error could be, for example, the usage of an input symbol that was not declared in the alphabet. In this case, the respective transition is simply ignored.

        Parameters:
        line - the line where the error occurred
        col - the column where the error occurred
        msgFmt - a format string of the message (see MessageFormat)
        args - the arguments of the message
      • warning

        void warning​(int line,
                     int col,
                     String msgFmt,
                     Object... args)
        Called when a warning is raised during parsing.

        A warning could be raised when, for example, an unrecognized option is used for a state.

        Parameters:
        line - the line where the warning was raised
        col - the column where the warning was raised
        msgFmt - a format string of the message (see MessageFormat)
        args - the arguments of the message