code: public void sortbyselection(List<String> sortFlds, List<Integer> sortDirs) {
  		moveToId(-1);
  		int i = 0;
  		while (super.next()) {
  			int minId = findSmallestFrom(i, sortFlds, sortDirs);
  			if (minId != i) {
  				swapRecords(i, minId);
  			}
  			moveToId(i);
  			i++;
  		}
  	}
docs: Selection sort. The values of sort directions are defined in
  {@link RecordComparator}.
  
  @param sortFlds
  the list of sorted fields
  @param sortDirs
  the list of sorting directions