public new System.Object Clone() { var basePlanClone = base.Clone() as Plan; var newPlan = new PlanSchedule(basePlanClone, new HashSet <Tuple <IPlanStep, IPlanStep> >(Cntgs.edges)); return(newPlan); }
public static IPlan CreateInitialPlan(List <IPredicate> Initial, List <IPredicate> Goal) { var initialPlan = new PlanSchedule(new Plan(new State(Initial) as IState, new State(Goal) as IState), new List <Tuple <IPlanStep, IPlanStep> >()); foreach (var goal in Goal) { initialPlan.Flaws.Add(initialPlan, new OpenCondition(goal, initialPlan.GoalStep as IPlanStep)); } initialPlan.Orderings.Insert(initialPlan.InitialStep, initialPlan.GoalStep); return(initialPlan); }