sa = new SelectedAction(cbe.getAssetID(), bestActionEvaluation, permittedVariants);
sa = new SelectedAction(bestActionEvaluation, permittedVariants, Math.round(knob.getPatienceFactor()*bestVariantEvaluation.getExpectedTransitionTime()));
  private SelectedAction selectBest(CostBenefitEvaluation cbe, ActionSelectionKnob knob) {        ActionEvaluation bestActionEvaluation = null;        VariantEvaluation bestVariantEvaluation = null;        double bestBenefit = -1000000.0;        SelectedAction sa =  null;        // iterate thru all Actions & Variants        Collection actionEvaluations = cbe.getActionEvaluations().values();        Iterator actionIter = actionEvaluations.iterator();        while (actionIter.hasNext()) {            ActionEvaluation thisActionEvaluation = (ActionEvaluation) actionIter.next();            Action thisAction = thisActionEvaluation.getAction();            Collection variantEvaluations = thisActionEvaluation.getVariantEvaluations().values();            Iterator variantIter = variantEvaluations.iterator();            while (variantIter.hasNext()) {                VariantEvaluation thisVariantEvaluation = (VariantEvaluation) variantIter.next();                if ((thisVariantEvaluation.getPredictedBenefit() > bestBenefit)                  && (!thisVariantEvaluation.triedP())) {                    bestBenefit = thisVariantEvaluation.getPredictedBenefit();                    bestActionEvaluation = thisActionEvaluation;                        bestVariantEvaluation = thisVariantEvaluation;                }            }        }        if (bestBenefit > 0) {            HashSet permittedVariants = new HashSet();            permittedVariants.add(bestVariantEvaluation);            sa = new SelectedAction(cbe.getAssetID(), bestActionEvaluation, permittedVariants);        }                return sa;    }