java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.matheclipse.parser.client.math.MathException
org.matheclipse.parser.client.SyntaxError
- All Implemented Interfaces:
Serializable
public class SyntaxError
extends org.matheclipse.parser.client.math.MathException
Exception for a syntax error detected by the MathEclipse parser.
- See Also:
- Serialized Form
-
Constructor Summary
Constructors Constructor Description SyntaxError(int startOffset, int rowIndx, int columnIndx, String currentLine, String error, int length)
SyntaxError exception. -
Method Summary
Modifier and Type Method Description int
getColumnIndex()
column index where the error occurred (offset relative to rowIndex).String
getCurrentLine()
source code line, where the error occurred.String
getError()
the error string.int
getLength()
length of the error.String
getMessage()
Gets the message.int
getRowIndex()
row index where the error occurred.int
getStartOffset()
offset where the error occurred.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Constructor Details
-
SyntaxError
public SyntaxError(int startOffset, int rowIndx, int columnIndx, String currentLine, String error, int length)SyntaxError exception.- Parameters:
startOffset
- the start offsetrowIndx
- the row indxcolumnIndx
- the column indxcurrentLine
- the current lineerror
- the errorlength
- the length
-
-
Method Details
-
getMessage
Gets the message.- Overrides:
getMessage
in classThrowable
- Returns:
- the message
-
getStartOffset
public int getStartOffset()offset where the error occurred.- Returns:
- the start offset
-
getColumnIndex
public int getColumnIndex()column index where the error occurred (offset relative to rowIndex).- Returns:
- the column index
-
getCurrentLine
source code line, where the error occurred.- Returns:
- the current line
-
getError
the error string.- Returns:
- the error
-
getLength
public int getLength()length of the error.- Returns:
- the length
-
getRowIndex
public int getRowIndex()row index where the error occurred.- Returns:
- the row index
-