/** * This will return the line number of the error, if possible * Otherwise it will be -1 */ public int getLine() { return this.descr != null ? this.descr.getLine() : -1; }
/** * This will return the line number of the error, if possible * Otherwise it will be -1 */ public int getLine() { return this.descr != null ? this.descr.getLine() : -1; }
public int getLine() { return this.input.getLine(); }
public String positionAsString() { return "[Line: " + getLine() + ", Column: " + getColumn() + "]"; } }
public FactTemplateError(final Package pkg, final BaseDescr descr, final Object object, final String message) { super(descr.getResource()); this.namespace = pkg.getName(); this.pkg = pkg; this.descr = descr; this.object = object; this.message = message; this.line = new int[] { ( this.descr != null ) ? this.descr.getLine() : -1 }; }
public FieldTemplateError(final Package pkg, final BaseDescr descr, final Object object, final String message) { super(descr.getResource()); this.namespace = pkg.getName(); this.pkg = pkg; this.descr = descr; this.object = object; this.message = message; this.line = new int[] { ( this.descr != null ) ? this.descr.getLine() : -1 }; }
public static void copyErrorLocation(Exception e, BaseDescr descr) { if (e instanceof CompileException) { CompileException compileException = (CompileException)e; compileException.setLineNumber(descr.getLine()); compileException.setColumn(descr.getColumn()); } }
public void copyLocation( BaseDescr d ) { this.setLocation( d.getLine(), d.getColumn() ); this.setEndLocation( d.getEndLine(), d.getEndColumn() ); this.setStartCharacter( d.getStartCharacter() ); this.setEndCharacter( d.getEndCharacter() ); }