code: public static IUnitizingAnnotationUnit findNextUnit(
  			final Iterator<IUnitizingAnnotationUnit> units, int raterIdx,
  			final Object category) {
  		while (units.hasNext()) {
  			IUnitizingAnnotationUnit result = units.next();
  			if (category != null && !category.equals(result.getCategory())) {
                  continue;
              }
  			if (raterIdx < 0 || result.getRaterIdx() == raterIdx) {
                  return result;
              }
  		}
  		return null;
  	}
docs: Utility method for moving on the cursor of the given iterator until
  a unit of the specified rater and category is returned. Both
  the rater index and the category may be null if those filter
  conditions are to be ignored.