throw new BlackboardException("publishAdd of miswired PlanElement (task already has other PE): " + existingPE);
e =  new BlackboardException("publishAdd of miswired PlanElement (task already has other PE): " + existingPE); } if (e != null) { logger.error("PlanElement.addingToBlackboard", e); throw e;
  public void addingToBlackboard(Subscriber s) {    Task t = getTask();    Date comdate = t.getCommitmentDate();    if (comdate != null) {      // make sure the current planning time is before commitment time      long curTime = s.getClient().currentTimeMillis();      // Could allow a 5 second buffer perhaps?      // IE: if (curTime > comdate.getTime() + 5000)      if ( curTime  > comdate.getTime() ) {        // its after the commitment time - shouldn't publish the object	// But for now we do so anyhow        logger.warn("publishAdd of "+this + " " + (curTime - comdate.getTime()) + " millis past commitmenttime "+comdate + " at curTime: " + (new Date(curTime)) + " by Subscriber " + s);      }    }    PlanElement existingPE = t.getPlanElement();    if (existingPE == null) {      ((TaskImpl)t).privately_setPlanElement(this);    } else if (existingPE == this) {      throw new BlackboardException("publishAdd of miswired PlanElement (task already wired to this PE): " + this);    } else {      throw new BlackboardException("publishAdd of miswired PlanElement (task already has other PE): " + existingPE);    }  }