public static Set < Integer > convertRowIndicesToModel ( JTable table , Iterable < ? extends Integer > viewRows ) { Set < Integer > modelRows = new LinkedHashSet < Integer > ( ) ; for ( Integer viewRow : viewRows ) { int modelRow = table . convertRowIndexToModel ( viewRow ) ; modelRows . add ( modelRow ) ; } return modelRows ; }
Convert all of the given view row indices to model row indices for the given table