Module technology.sola.json
Class InvalidCharacterException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
technology.sola.json.tokenizer.exception.InvalidCharacterException
- All Implemented Interfaces:
Serializable,SolaJsonErrorWithLineAndColumn
@NullMarked
public class InvalidCharacterException
extends RuntimeException
implements SolaJsonErrorWithLineAndColumn
Exception for when an invalid character is found during tokenization.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionInvalidCharacterException(char invalidCharacter, int line, int column) Creates a new instance of this exception. -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
InvalidCharacterException
public InvalidCharacterException(char invalidCharacter, int line, int column) Creates a new instance of this exception.- Parameters:
invalidCharacter- the invalid characterline- line where the invalid character was foundcolumn- column where the invalid character was found
-
-
Method Details
-
getInvalidCharacter
public char getInvalidCharacter()- Returns:
- the invalid character
-
getLine
public int getLine()- Specified by:
getLinein interfaceSolaJsonErrorWithLineAndColumn- Returns:
- the line where the syntax error began
-
getColumn
public int getColumn()- Specified by:
getColumnin interfaceSolaJsonErrorWithLineAndColumn- Returns:
- the column where the syntax error began
-