TPFDDLoggerFactory.createLogger().logMessage(Logger.NORMAL, Logger.GENERIC, "Tree.doRollup - before " + node + " s " + nodeStart + " e " + nodeEnd);
TPFDDLoggerFactory.createLogger().logMessage(Logger.NORMAL, Logger.GENERIC, "Tree.doRollup - before " + node + " s " + nodeStart + " e " + nodeEnd + " mode " + mode);
  public synchronized Object [] doRollup (Node node) {	Date nodeStart = node.getActualStart ();	Date nodeEnd   = node.getActualEnd   ();	String from = node.getFrom ();	String to = node.getTo ();	int mode = node.getMode ();	Set fromSet = new HashSet ();	if (from != null && from.length()>0)	  fromSet.add(from);	Set toSet   = new HashSet ();	if (to != null && to.length()>0)	  toSet.add(to);		if (debug)	  TPFDDLoggerFactory.createLogger().logMessage(Logger.NORMAL, Logger.GENERIC, "Tree.doRollup - before " + node + " s " + nodeStart + " e " + nodeEnd);		for (int i = 0; i < node.getChildCount (); i++) {	  Node childNode = getNode (node.getChildUID (i));	  Object [] rollup = doRollup (childNode);	  Date childStart = (Date) rollup[0];	  Date childEnd   = (Date) rollup[1];	  Set childFromSet = (Set) rollup[2];	  Set childToSet = (Set) rollup[3];	  int childMode = ((Integer) rollup[4]).intValue();	  	  if (childStart != null && 		  (nodeStart == null || childStart.before (nodeStart))) {		nodeStart = childStart;		fromSet = childFromSet;	  }	  if (childEnd != null && 		  (nodeEnd == null || childEnd.after (nodeEnd))) {		nodeEnd = childEnd;		toSet = childToSet;	  }	  //	  if (!(node instanceof LegNode) && !(node instanceof CargoInstance)) {	  if (node instanceof Org) {		fromSet.addAll (childFromSet);		toSet.addAll   (childToSet);	  }	  mode = getMode (mode, childMode);	}	if (debug)	  TPFDDLoggerFactory.createLogger().logMessage(Logger.NORMAL, Logger.GENERIC, "Tree.doRollup - after " + node + " s " + nodeStart + " e " + nodeEnd);	node.setActualStart (nodeStart);	node.setActualEnd   (nodeEnd);	node.setFrom (trim(fromSet.toString()));	node.setTo   (trim(toSet.toString()));	node.setMode (mode);		return new Object [] { nodeStart, nodeEnd, fromSet, toSet, new Integer(mode)};  }