long endTime = taskUtils.getEndTime(task); Object org = TaskUtils.getCustomer(task); if (org != null) { Long lastActualSeen = (Long)customerHash.get(org); if ((lastActualSeen == null) || (endTime > lastActualSeen.longValue())) { customerHash.put(org, new Long(endTime)); } } int bucket = convertTimeToBucket(endTime); while (bucket >= dueOutList.size()) { dueOutList.add(new ArrayList()); } ArrayList list = (ArrayList)dueOutList.get(bucket); list.add(task); }
  public void addWithdrawRequisition(Task task) {    if (!task.getVerb().equals (Constants.Verb.WITHDRAW)) { // assertion/pre-condition      Exception exception = new Exception ("Adding non-WITHDRAW task to inventory BG");      logger.error(".addWithdrawRequisition - adding non-WITHDRAW task " + task + 		   " to inventory BG.", exception);    }    long endTime = taskUtils.getEndTime(task);    Object org = TaskUtils.getCustomer(task);    if (org != null) {      Long lastActualSeen = (Long)customerHash.get(org);      if ((lastActualSeen == null) || (endTime > lastActualSeen.longValue())) {	customerHash.put(org, new Long(endTime));      }    }    int bucket = convertTimeToBucket(endTime);    while (bucket >= dueOutList.size()) {      dueOutList.add(new ArrayList());    }    ArrayList list = (ArrayList)dueOutList.get(bucket);    list.add(task);  }