Beispiel #1
0
  public List<String> getSamples() {
    List<String> samples = new ArrayList<String>();
    for (Inventory inventory : inventories) {
      samples.addAll(Arrays.asList(inventory.getSamples()));
    }

    return samples;
  }
Beispiel #2
0
 public Inventory getInventoryByGermplasmId(String germplasmId) {
   List<Inventory> inventories = getInventories();
   for (Inventory inventory : inventories) {
     if (germplasmId.equals(inventory.getGermplasmId())) {
       return inventory;
     }
   }
   throw new RuntimeException(
       "Inventory not found for germplasm " + germplasmId + " in project " + getProjectId());
 }
Beispiel #3
0
 private boolean hasSingleSelectionInventory() {
   for (Inventory inventory : getInventories()) {
     if (inventory.isSingleSelection()) {
       setProjectError(
           "Project \""
               + getProjectId()
               + "\" has inventory that contains Single Selection , this is not supported\n");
       return true;
     }
   }
   return false;
 }