int[] aspectTypes = new int[aspectValues.length]; double[] results = new double[aspectValues.length]; for (int j = 0; j < aspectValues.length; j++) { aspectTypes [j] = aspectValues[j].getAspectType (); results [j]     = aspectValues[j].getValue (); } expand.showPreferences (parentTask, aspectTypes, results);
expand.showPreferences (parentTask, aspectValues);
  public List makeAggregation(UTILPlugin creator,				     PlanningFactory ldmf,				     Plan realityPlan,				     Vector parentTasks, 				     Verb whatVerb,				     Vector prepPhrases,				     Vector directObjects,				     Vector preferences,				     MessageAddress sourceClusterID,				     AspectValue [] aspectValues,				     double confidence) {    List stuffToPublish = new ArrayList ();    NewMPTask mptask = makeMPSubTask(ldmf,						   realityPlan,						   parentTasks.elements(),						   whatVerb,						   prepPhrases.elements(),						   assetHelper.makeAssetGroup(ldmf, directObjects),						   preferences.elements(),						   Priority.UNDEFINED,						   sourceClusterID);    // create the new composition    NewComposition comp = ldmf.newComposition ();    comp.setCombinedTask(mptask);    comp.setDistributor(AllocationResultDistributor.DEFAULT);    // comp.setIsPropagating();    // create the new MP task that represents all subtasks    mptask.setComposition (comp);    mptask.setParentTasks (parentTasks.elements());    stuffToPublish.add (mptask);    stuffToPublish.add (comp);    // create aggregations for each parent task    for (Iterator i = parentTasks.iterator(); i.hasNext();){      Task parentTask = (Task)i.next();      //      if (logger.isDebugEnabled())      //	alloc.setLogger (logger);      boolean isSuccess = !alloc.exceedsPreferences (parentTask, aspectValues);      if (!isSuccess) {	logger.warn ("UTILAggregate.makeAggregation - making failed aggregation for " + parentTask);	int[] aspectTypes = new int[aspectValues.length];	double[] results = new double[aspectValues.length];	for (int j = 0; j < aspectValues.length; j++) {	  aspectTypes [j] = aspectValues[j].getAspectType ();	  results [j]     = aspectValues[j].getValue ();	}	expand.showPreferences (parentTask, aspectTypes, results);      }	        //      if (logger.isDebugEnabled())      //	UTILAllocate.setLogger (logger);      AllocationResult estAR = ldmf.newAVAllocationResult(confidence,							  isSuccess,							  aspectValues);      Aggregation agg = ldmf.createAggregation(parentTask.getPlan(),					       parentTask,					       comp,					       estAR);      if (logger.isDebugEnabled())	logger.debug ("UTILAggregate.makeAggregation - Making aggregation for task " + parentTask.getUID () + 		      " agg " + agg.getUID());	      stuffToPublish.add (agg);      comp.addAggregation(agg);    }    return stuffToPublish;  }