UNPKG

ifc-expressions

Version:

Parsing and evaluation of IFC expressions

19 lines (18 loc) 754 B
import { BaseErrorListener, } from "antlr4ng"; import { isNullish, isPresent } from "./util/IfcExpressionUtils.js"; import { SyntaxErrorException } from "./error/SyntaxErrorException.js"; export class IfcExpressionErrorListener extends BaseErrorListener { validationException(validationException) { this.exception = validationException; } syntaxError(recognizer, offendingSymbol, line, column, msg, e) { this.exception = new SyntaxErrorException(isNullish(offendingSymbol) ? "[no symbol]" : offendingSymbol.text, line, column, msg); } isErrorOccurred() { return isPresent(this.exception); } getException() { return this.exception; } } //# sourceMappingURL=IfcExpressionErrorListener.js.map