- Timestamp:
- 12/26/10 03:51:30 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ParallelEngine/HeuristicLab.Selection/3.3/GenderSpecificSelector.cs
r4722 r5177 140 140 /// <exception cref="InvalidOperationException">Thrown when <see cref="NumberOfSelectedSubScopesParameter"/> returns an odd number.</exception> 141 141 /// <returns>Returns Apply of <see cref="AlgorithmOperator"/>.</returns> 142 public override IOperation Apply( ) {142 public override IOperation Apply(IExecutionContext context) { 143 143 int count = NumberOfSelectedSubScopesParameter.ActualValue.Value; 144 144 if (count % 2 > 0) throw new InvalidOperationException(Name + ": There must be an equal number of sub-scopes to be selected."); 145 145 FemaleSelector.NumberOfSelectedSubScopesParameter.Value = new IntValue(count / 2); 146 146 MaleSelector.NumberOfSelectedSubScopesParameter.Value = new IntValue(count / 2); 147 return base.Apply( );147 return base.Apply(context); 148 148 } 149 149
Note: See TracChangeset
for help on using the changeset viewer.