private int convertToModel(int index) { return pipeline != null ? pipeline.convertRowIndexToModel(index) : index; }
private int convertToModel(int index) { // TODO: JW: check for valid index? must be < pipeline.getOutputSize() return (pipeline != null) && pipeline.isAssigned() ? pipeline.convertRowIndexToModel(index) : index; }
/** * Convert row index from view coordinates to model coordinates accounting * for the presence of sorters and filters. * * @param row row index in view coordinates * @return row index in model coordinates */ public int convertRowIndexToModel(int row) { return getFilters() != null ? getFilters().convertRowIndexToModel(row) : row; }
/** * Convert row index from view coordinates to model coordinates accounting * for the presence of sorters and filters. * * @param viewIndex index in view coordinates * @return index in model coordinates * @throws IndexOutOfBoundsException if viewIndex < 0 or viewIndex >= getElementCount() */ public int convertIndexToModel(int viewIndex) { return isFilterEnabled() ? getFilters().convertRowIndexToModel( viewIndex) : viewIndex; }