public int getLineNumber () { try { return pos.getLine (); } catch (IOException ex) { // what else? return 0; } }
public int getLineNumber () { try { return pos.getLine (); } catch (IOException ex) { // what else? return 0; } }
public int getLineNumber() { try { return pos.getLine(); } catch (IOException ex) { // what else? return 0; } }
public ErrorDescriptionNode(ErrorDescription ed, Map<ErrorDescription, List<FixDescription>> errors2Fixes) { super(new FixChildren(ed, errors2Fixes.get(ed))); this.ed = ed; int line = -1; try { line = ed.getRange().getBegin().getLine(); } catch (IOException ex) { Exceptions.printStackTrace(ex); } setDisplayName((line != (-1) ? (line + ":") : "") + ed.getDescription()); setIconBaseWithExtension("org/netbeans/modules/java/hints/analyzer/ui/warning-glyph.gif"); }
public void open() { try { PositionRef pos = ed.getRange().getBegin(); int line = pos.getLine(); int column = pos.getColumn(); Line l = pos.getCloneableEditorSupport().getLineSet().getCurrent(line); l.show(Line.SHOW_GOTO, column); } catch (IOException ex) { Exceptions.printStackTrace(ex); } }
public FixNode(ErrorDescription ed, FixDescription fix) { super(Children.LEAF, Lookups.fixed(new OpenCookieImpl(ed), fix)); this.fix = fix; int line = -1; try { line = ed.getRange().getBegin().getLine(); } catch (IOException ex) { Exceptions.printStackTrace(ex); } setDisplayName((line != (-1) ? (line + ":") : "") + fix.getText() + "(" + ed.getDescription() + ")"); setIconBaseWithExtension("org/netbeans/modules/java/hints/analyzer/ui/suggestion.png"); fix.addChangeListener(this); }
severityToTaskListString(hint.getSeverity()), hint.getDescription(), hint.getRange().getBegin().getLine()+1); tasks.add(task); } catch (IOException ioe) {