Changeset 14128 for branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Encodings/PackingSequence/Moves/Insertion/InsertionMoveGenerator.cs
- Timestamp:
- 07/20/16 14:02:36 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Encodings/PackingSequence/Moves/Insertion/InsertionMoveGenerator.cs
r14046 r14128 23 23 using HeuristicLab.Common; 24 24 using HeuristicLab.Core; 25 using HeuristicLab.Encodings.PermutationEncoding; 25 26 using HeuristicLab.Operators; 26 27 using HeuristicLab.Optimization; … … 37 38 get { return false; } 38 39 } 39 public ILookupParameter<P ackingSequenceEncoding> PackingSequenceParameter {40 get { return (ILookupParameter<P ackingSequenceEncoding>)Parameters["PackingSequence"]; }40 public ILookupParameter<Permutation> PackingSequenceParameter { 41 get { return (ILookupParameter<Permutation>)Parameters["PackingSequence"]; } 41 42 } 42 public ILookupParameter<IPackingMove > PackingMoveParameter {43 get { return (LookupParameter<IPackingMove >)Parameters["PackingMove"]; }43 public ILookupParameter<IPackingMove<Permutation>> PackingMoveParameter { 44 get { return (LookupParameter<IPackingMove<Permutation>>)Parameters["PackingMove"]; } 44 45 } 45 46 protected ScopeParameter CurrentScopeParameter { … … 52 53 public InsertionMoveGenerator() 53 54 : base() { 54 Parameters.Add(new LookupParameter<P ackingSequenceEncoding>("PackingSequence", "The Sequence vector for which moves should be generated."));55 Parameters.Add(new LookupParameter<IPackingMove >("PackingMove", "The moves that should be generated in subscopes."));55 Parameters.Add(new LookupParameter<Permutation>("PackingSequence", "The Sequence vector for which moves should be generated.")); 56 Parameters.Add(new LookupParameter<IPackingMove<Permutation>>("PackingMove", "The moves that should be generated in subscopes.")); 56 57 Parameters.Add(new ScopeParameter("CurrentScope", "The current scope where the moves should be added as subscopes.")); 57 58 } 58 59 59 60 public override IOperation Apply() { 60 P ackingSequenceEncodingps = PackingSequenceParameter.ActualValue;61 Permutation ps = PackingSequenceParameter.ActualValue; 61 62 InsertionMove[] moves = GenerateMoves(ps); 62 63 Scope[] moveScopes = new Scope[moves.Length]; … … 69 70 } 70 71 71 protected abstract InsertionMove[] GenerateMoves(P ackingSequenceEncoding PackingSequence);72 protected abstract InsertionMove[] GenerateMoves(Permutation packingSequence); 72 73 } 73 74 }
Note: See TracChangeset
for help on using the changeset viewer.