nt.setWorkflow(null); nt.privately_resetPlanElement();
  public synchronized Object clone() {    // make sure the clone gets a new oid.    TaskImpl nt = new TaskImpl();    // directiveimpl    nt.setSource(getSource());    nt.setDestination(getDestination());    //nt.setPlan(getPlan());     // duplicate the immutable parts    nt.setVerb(getVerb());    nt.setDirectObject(getDirectObject());    nt.setPrepositionalPhrases(getPrepositionalPhrases());    nt.setPreferences(getPreferences());    nt.setPriority(getPriority());    nt.setAuxiliaryQueryTypes(getAuxiliaryQueryTypes());    nt.setContext(getContext());    // parent of the clone is our parent.    nt.setParentTaskUID(getParentTaskUID());    nt.setWorkflow(null);    nt.privately_resetPlanElement();    return nt;  }