예제 #1
0
        public new System.Object Clone()
        {
            var CompositeBase = base.Clone() as Composite;
            var newCntgs      = new List <Tuple <IPlanStep, IPlanStep> >();

            foreach (var cntg in Cntgs)
            {
                newCntgs.Add(cntg);
            }
            var theClone = new CompositeSchedule(CompositeBase, newCntgs)
            {
                InitialActionSeg = InitialActionSeg.Clone(),
                FinalActionSeg   = FinalActionSeg.Clone(),
                InitialAction    = InitialAction.Clone() as IPlanStep,
                FinalAction      = FinalAction.Clone() as IPlanStep,
                InitialCamAction = InitialCamAction.Clone() as CamPlanStep,
                FinalCamAction   = FinalCamAction.Clone() as CamPlanStep
            };

            return(theClone);
        }
예제 #2
0
        public new System.Object Clone()
        {
            var baseDecomp = base.Clone() as Decomposition;

            var newSubsteps = new List <CamPlanStep>();

            foreach (var substep in discourseSubSteps)
            {
                var newsubstep = substep.Clone() as CamPlanStep;
                newsubstep.Action = substep.Action.Clone() as Operator;
                newSubsteps.Add(newsubstep);
            }

            return(new TimelineDecomposition(baseDecomp, fabCntgs.ToList(), discCntgs.ToList(), newSubsteps, fabConstraints.ToList(), discConstraints.ToList(), discOrderings.ToList(), discLinks.ToList(), fabulaActionNameMap.ToDictionary(x => x.Key, x => x.Value))
            {
                InitialActionSeg = InitialActionSeg.Clone(),
                FinalActionSeg = FinalActionSeg.Clone(),
                InitialAction = InitialAction.Clone() as IPlanStep,
                FinalAction = FinalAction.Clone() as IPlanStep,
                InitialCamAction = InitialCamAction.Clone() as CamPlanStep,
                FinalCamAction = FinalCamAction.Clone() as CamPlanStep
            });
        }