Class ParseException

    • Constructor Detail

      • ParseException

        public ParseException​(String message,
                              String input,
                              int position,
                              Throwable cause)
        Create instance of ParseException.
        Parameters:
        message - exception message.
        input - parser input.
        position - position where parse exception occurred.
        cause - underlying exception, if any.
      • ParseException

        public ParseException​(String message,
                              CharBuffer input,
                              int position,
                              Throwable cause)
        Create instance of ParseException.
        Parameters:
        message - exception message.
        input - parser input.
        position - position where parse exception occurred.
        cause - underlying exception, if any.
      • ParseException

        public ParseException​(String message,
                              String input,
                              int position)
        Create instance of ParseException.
        Parameters:
        message - exception message.
        input - parser input.
        position - position where parse exception occurred.
      • ParseException

        public ParseException​(String message,
                              CharBuffer input,
                              Throwable cause)
        Create instance of ParseException.
        Parameters:
        message - exception message.
        input - current state of input buffer.
        cause - underlying exception, if any.
      • ParseException

        public ParseException​(String message,
                              CharBuffer input)
        Create instance of ParseException.
        Parameters:
        message - exception message.
        input - current state of input buffer.
    • Method Detail

      • getData

        public String getData()
        Return the raw data on which the parser operated..
        Returns:
        the raw data.
      • getPosition

        public int getPosition()
        Return the approximate position where the parse error occurred.
        Returns:
        the position.
      • getDiagnostics

        public String getDiagnostics()
        Gets additional diagnostics.
        Returns:
        two lines of data; first contains the raw parse data enclosed in ">>" and "<<", the second ASCII artwork with "^" pointing to the parse position, followed by the actual exception message.