public void Initialize(ISequenceFlowContainer flowContainer) { ISequenceGroup sequenceGroup = flowContainer as ISequenceGroup; this.Info.Hash = sequenceGroup.Info.Hash; this.Info.Modified = true; this.Info.ModifiedTime = DateTime.Now; this.Info.Path = sequenceGroup.Info.SequenceParamFile; this.Info.Version = sequenceGroup.Info.Version; this.VariableValues = new VariableInitValueCollection(); foreach (IVariable variable in sequenceGroup.Variables) { VariableInitValue variableInitValue = new VariableInitValue() { Name = variable.Name }; variableInitValue.Initialize(variable); this.VariableValues.Add(variableInitValue); } this.SetUpParameters = new SequenceParameter(); this.SetUpParameters.Initialize(sequenceGroup.SetUp); this.SequenceParameters = new SequenceParameterCollection(); foreach (ISequence sequence in sequenceGroup.Sequences) { SequenceParameter parameter = new SequenceParameter(); parameter.Initialize(sequence); SequenceParameters.Add(parameter); } this.TearDownParameters = new SequenceParameter(); this.TearDownParameters.Initialize(sequenceGroup.TearDown); }
public void Initialize(ISequenceFlowContainer flowContainer) { ISequence sequence = flowContainer as ISequence; this.Index = sequence.Index; this.StepParameters = new SequenceStepParameterCollection(); foreach (ISequenceStep sequenceStep in sequence.Steps) { SequenceStepParameter stepParameter = new SequenceStepParameter(); stepParameter.Initialize(sequenceStep); this.StepParameters.Add(stepParameter); } this.VariableValues = new VariableInitValueCollection(); foreach (IVariable variable in sequence.Variables) { VariableInitValue initValue = new VariableInitValue() { Name = variable.Name }; initValue.Initialize(variable); this.VariableValues.Add(initValue); } }
public ISequenceDataContainer Clone() { VariableInitValue variableInitValue = new VariableInitValue() { Name = this.Name, Value = this.Value }; return(variableInitValue); }