Class KStringParseException

All Implemented Interfaces:
Serializable

public class KStringParseException extends KStringException
Exception class used for KString parsing errors.
Author:
Christopher Mindus
See Also:
  • Constructor Details

    • KStringParseException

      public KStringParseException(String message, String inputString, int parsePosition)
      Constructs a KString parse exception.
      Parameters:
      message - The message string.
      inputString - The HTML input string.
      parsePosition - The error position in the input string.
  • Method Details

    • getParsePosition

      public int getParsePosition()
      Gets the parsing position where the error occurred.
      Returns:
      The position in the input string that caused the error.
    • getInputString

      public String getInputString()
      Gets the input string that caused the error.
      Returns:
      The input string for the error.
    • getFixedCharacterOutput

      public String getFixedCharacterOutput()
      Formats a string that can be used by e.g. System.out to display the parse error. The output consists of two lines separated with the system line separator where the first line is the input string, the second line the indication to where the error is located.
      Returns:
      A fixed format string consisting of two lines.