((NewWorkflow)oldRefill.getWorkflow()).removeTask(oldRefill);
  public void compareRefills(ArrayList newRefills, ArrayList oldRefills, Inventory inv) {    //Rescind all old Refill Tasks    Iterator oldIter = oldRefills.iterator();    while (oldIter.hasNext()) {      Task oldRefill = (Task) oldIter.next();      // check for a null in the refills list!      if (oldRefill != null) {	inventoryPlugin.publishRemove(oldRefill);      }    }    //Process all new Refill Tasks    LogisticsInventoryPG thePG = (LogisticsInventoryPG)inv.	searchForPropertyGroup(LogisticsInventoryPG.class);    Iterator newIter = newRefills.iterator();    while (newIter.hasNext()) {      Task newRefill = (Task) newIter.next();      // apply the Task to the LogisticsInventoryBG      thePG.addRefillRequisition(newRefill);      // hook the task in with the MaintainInventory workflow and publish      inventoryPlugin.publishRefillTask(newRefill, inv);    }  }