public class QueryException extends Exception
Constructor and Description |
---|
QueryException(InputInfo info,
QNm name,
String message,
Object... ext)
Constructor, specifying the error code and message as string.
|
QueryException(InputInfo info,
QueryError error,
Object... ext)
Default constructor.
|
QueryException(String message)
Constructor, specifying a simple error message.
|
QueryException(Throwable cause)
Constructor, specifying an exception or error.
|
Modifier and Type | Method and Description |
---|---|
QueryException |
add(InputInfo ii)
Adds an input info to the stack.
|
int |
column()
Returns the error column.
|
QueryError |
error()
Returns the error.
|
String |
file()
Returns the file.
|
String |
getLocalizedMessage() |
String |
getMessage() |
InputInfo |
info()
Returns the input info.
|
QueryException |
info(InputInfo ii)
Sets input info.
|
boolean |
isCatchable()
Checks if this exception can be caught by a
try/catch expression. |
int |
line()
Returns the error line.
|
int |
markedColumn()
Returns the marked error column.
|
QueryException |
notCatchable()
Makes this exception uncatchable by a
try/catch expression. |
QNm |
qname()
Returns the error name.
|
StringList |
suggest()
Returns suggestions for code suggestions.
|
QueryException |
suggest(InputParser qp,
StringList sug)
Sets code suggestions.
|
Value |
value()
Returns the error value.
|
QueryException |
value(Value val)
Sets the error value.
|
addSuppressed, fillInStackTrace, getCause, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public QueryException(Throwable cause)
QueryError.BASX_GENERIC_X
will be set
as error code.cause
- exception or errorpublic QueryException(String message)
QueryError.BASX_GENERIC_X
will be set
as error code.message
- error messagepublic QueryException(InputInfo info, QueryError error, Object... ext)
info
- input infoerror
- error referenceext
- error extensionpublic int column()
public int markedColumn()
public int line()
public String file()
public StringList suggest()
public QueryException suggest(InputParser qp, StringList sug)
qp
- query parsersug
- code suggestionspublic QueryException add(InputInfo ii)
ii
- input infopublic QueryException info(InputInfo ii)
ii
- input infopublic InputInfo info()
public QueryException value(Value val)
val
- error valuepublic QNm qname()
public QueryError error()
public Value value()
public String getLocalizedMessage()
getLocalizedMessage
in class Throwable
public String getMessage()
getMessage
in class Throwable
public boolean isCatchable()
try/catch
expression.public QueryException notCatchable()
try/catch
expression.Copyright © 2005–2015 BaseX Team. All rights reserved.