class Crop{ String name; int bmu; HashSet spn = new HashSet(); //species number -- unique HashSet geono = new HashSet(); HashSet id = new HashSet(); int wild, bred, cultivar; //tally the # of species that were recorded as wild or bred (Breeder's Line) float x,y; float dx, dy; Crop(){ name = ""; wild = 0; bred = 0; cultivar = 0; } } class cropBmuComparator implements Comparator{ int compare(Object cropA , Object cropB){ Crop CropA = (Crop) cropA; Crop CropB = (Crop) cropB; if(CropA.bmu < CropB.bmu) return -1; else if(CropA.bmu > CropB.bmu) return 1; else return 0; } }