- Timestamp:
- 07/12/16 18:02:28 (8 years ago)
- Location:
- branches/HeuristicLab.BinPacking
- Files:
-
- 11 edited
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking.2D/3.3/RectangularPackingShape.cs
r13606 r14043 33 33 [Item("RectangularPackingShape", "Represents the rectangular measures (width, height) of a two-dimensional bin-packing object.")] 34 34 [StorableClass] 35 public abstract class RectangularPackingShape : PackingShape<TwoDimensionalPacking>, I RegularPackingShape, IComparable<RectangularPackingShape> {35 public abstract class RectangularPackingShape : PackingShape<TwoDimensionalPacking>, IComparable<RectangularPackingShape> { 36 36 public int Height { 37 37 get { return ((IFixedValueParameter<IntValue>)Parameters["Height"]).Value.Value; } … … 73 73 } 74 74 75 public int CompareTo(object obj) {75 public override int CompareTo(object obj) { 76 76 var other = obj as RectangularPackingShape; 77 77 if (other != null) return CompareTo(other); … … 118 118 } 119 119 120 public void ApplyHorizontalOrientation() {120 public override void ApplyHorizontalOrientation() { 121 121 if (Width < Height) { 122 122 var aux = Width; -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking.3D/3.3/CuboidPackingShape.cs
r13608 r14043 32 32 [Item("CuboidPackingShape", "Represents the cuboid measures (width, height, depth) of a three-dimensional cuboidic bin-packing object.")] 33 33 [StorableClass] 34 public abstract class CuboidPackingShape : PackingShape<ThreeDimensionalPacking>, I RegularPackingShape, IComparable<CuboidPackingShape> {34 public abstract class CuboidPackingShape : PackingShape<ThreeDimensionalPacking>, IComparable<CuboidPackingShape> { 35 35 public IFixedValueParameter<IntValue> HeightParameter { 36 36 get { return (IFixedValueParameter<IntValue>)Parameters["Height"]; } … … 110 110 } 111 111 112 public int CompareTo(object obj) {112 public override int CompareTo(object obj) { 113 113 var other = (CuboidPackingShape)obj; 114 114 if (other != null) return CompareTo(other); … … 179 179 } 180 180 181 public void ApplyHorizontalOrientation() {181 public override void ApplyHorizontalOrientation() { 182 182 if (Width > Depth) { 183 183 var aux = Width; -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Analyzers/BestBinPackingSolutionAnalyzer.cs
r13605 r14043 38 38 public class BestBinPackingSolutionAnalyzer<D, B, I> : BinPackingAnalyzer<D, B, I>, IStochasticOperator 39 39 where D : class, IPackingDimensions 40 where B : PackingShape<D>, IPackingBin , IRegularPackingShape41 where I : PackingShape<D>, IPackingItem , IRegularPackingShape{40 where B : PackingShape<D>, IPackingBin 41 where I : PackingShape<D>, IPackingItem { 42 42 43 43 public ILookupParameter<IRandom> RandomParameter { -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/BinPackingProblem.cs
r14040 r14043 43 43 public abstract class BinPackingProblem<D, B, I> : SingleObjectiveHeuristicOptimizationProblem<IPackingPlanEvaluationAlgorithm, IPackingSolutionCreator> 44 44 where D : class, IPackingDimensions 45 where B : PackingShape<D>, IPackingBin, IRegularPackingShape,new()46 where I : PackingShape<D>, IPackingItem, IRegularPackingShape,new () {45 where B : PackingShape<D>, IPackingBin, new() 46 where I : PackingShape<D>, IPackingItem, new () { 47 47 48 48 … … 150 150 protected void ApplyHorizontalOrientation() { 151 151 PackingBinMeasures.ApplyHorizontalOrientation(); 152 foreach (I RegularPackingShape shape in PackingItemMeasures) {152 foreach (IPackingShape shape in PackingItemMeasures) { 153 153 shape.ApplyHorizontalOrientation(); 154 154 } -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Evaluators/BinUtilizationRegularIdenticalBinEvaluator.cs
r13608 r14043 34 34 public abstract class BinUtilizationRegularIdenticalBinEvaluator<D, B, I> : RegularSimpleRotationIdenticalBinPackingPlanEvaluator<D, B, I> 35 35 where D : class, IPackingDimensions 36 where B : PackingShape<D>, IPackingBin , IRegularPackingShape37 where I : PackingShape<D>, IPackingItem , IRegularPackingShape{36 where B : PackingShape<D>, IPackingBin 37 where I : PackingShape<D>, IPackingItem { 38 38 39 39 [StorableConstructor] -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Evaluators/PackingRatioRegularIdenticalBinEvaluator.cs
r13608 r14043 34 34 public abstract class PackingRatioRegularIdenticalBinEvaluator<D, B, I> : RegularSimpleRotationIdenticalBinPackingPlanEvaluator<D, B, I> 35 35 where D : class, IPackingDimensions 36 where B : PackingShape<D>, IPackingBin , IRegularPackingShape37 where I : PackingShape<D>, IPackingItem , IRegularPackingShape{36 where B : PackingShape<D>, IPackingBin 37 where I : PackingShape<D>, IPackingItem { 38 38 39 39 [StorableConstructor] -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Evaluators/RegularSimpleRotationIdenticalBinPackingPlanEvaluator.cs
r13608 r14043 33 33 public abstract class RegularSimpleRotationIdenticalBinPackingPlanEvaluator<D, B, I> : PackingPlanEvaluator<D, B, I> 34 34 where D : class, IPackingDimensions 35 where B : PackingShape<D>, IPackingBin , IRegularPackingShape36 where I : PackingShape<D>, IPackingItem , IRegularPackingShape{35 where B : PackingShape<D>, IPackingBin 36 where I : PackingShape<D>, IPackingItem { 37 37 38 38 #region Parameter Properties -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/HeuristicLab.Problems.BinPacking-3.3.csproj
r14040 r14043 282 282 <Compile Include="PackingDimensions.cs" /> 283 283 <Compile Include="PackingMoveEvaluator.cs" /> 284 <Compile Include="Interfaces\IRegularPackingShape.cs" />285 284 <Compile Include="Interfaces\IPackingBin.cs" /> 286 285 <Compile Include="Interfaces\IPackingItem.cs" /> -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/Interfaces/IPackingShape.cs
r13605 r14043 20 20 #endregion 21 21 22 using System; 22 23 using HeuristicLab.Core; 23 24 … … 25 26 // a packing shape represents a physical object of correct dimension (2d or 3d) 26 27 // packing bins (containers) and packing items are both packing shapes 27 public interface IPackingShape : IItem { } 28 public interface IPackingShape : IItem, IComparable { 29 int Volume { get; } 30 void ApplyHorizontalOrientation(); 31 } 28 32 } -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/PackingMoveEvaluator.cs
r13608 r14043 38 38 public abstract class PackingMoveEvaluator<D, B, I> : SingleSuccessorOperator, IPackingMoveEvaluator, IMoveOperator 39 39 where D : class, IPackingDimensions 40 where B : PackingShape<D>, IPackingBin , IRegularPackingShape41 where I : PackingShape<D>, IPackingItem , IRegularPackingShape{40 where B : PackingShape<D>, IPackingBin 41 where I : PackingShape<D>, IPackingItem { 42 42 public override bool CanChangeName { 43 43 get { return false; } -
branches/HeuristicLab.BinPacking/HeuristicLab.Problems.BinPacking/3.3/PackingShape.cs
r13608 r14043 79 79 } 80 80 81 public abstract void ApplyHorizontalOrientation(); 82 public abstract int CompareTo(object obj); 83 81 84 public IKeyedItemCollection<string, IParameter> Parameters { get; private set; } 82 85 } -
branches/HeuristicLab.BinPacking/old files/IRegularPackingShape.cs
r14042 r14043 25 25 ///A regularPackingShape has special geometric properties that allow special handling = Rectangle, Cuboid 26 26 public interface IRegularPackingShape : IPackingShape, IComparable { 27 int Volume { get; } 28 void ApplyHorizontalOrientation(); 27 29 28 } 30 29 }
Note: See TracChangeset
for help on using the changeset viewer.