Class DefaultDoubleSolution
java.lang.Object
org.uma.jmetal.solution.AbstractSolution<java.lang.Double>
org.uma.jmetal.solution.doublesolution.impl.DefaultDoubleSolution
- All Implemented Interfaces:
java.io.Serializable,DoubleSolution,Solution<java.lang.Double>
public class DefaultDoubleSolution extends AbstractSolution<java.lang.Double> implements DoubleSolution
Defines an implementation of a double solution. Each variable is given by a pair .
- Author:
- Antonio J. Nebro
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description DefaultDoubleSolution(int numberOfObjectives, int numberOfConstraints, java.util.List<Bounds<java.lang.Double>> boundsList)ConstructorDefaultDoubleSolution(int numberOfObjectives, java.util.List<Bounds<java.lang.Double>> boundsList)ConstructorDefaultDoubleSolution(java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Double,java.lang.Double>> bounds, int numberOfObjectives)Deprecated.UseDefaultDoubleSolution(int, List)instead.DefaultDoubleSolution(java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Double,java.lang.Double>> bounds, int numberOfObjectives, int numberOfConstraints)Deprecated.UseDefaultDoubleSolution(int, int, List)instead.DefaultDoubleSolution(DefaultDoubleSolution solution)Copy constructor -
Method Summary
Modifier and Type Method Description DefaultDoubleSolutioncopy()Bounds<java.lang.Double>getBounds(int index)It is often the case that we use both bounds together.java.lang.DoublegetLowerBound(int index)Deprecated.UsegetBounds(int).getLowerBound()instead.java.lang.DoublegetUpperBound(int index)Deprecated.UsegetBounds(int).getUpperBound()instead.Methods inherited from class org.uma.jmetal.solution.AbstractSolution
attributes, constraints, equals, hashCode, objectives, toString, variablesMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.uma.jmetal.solution.Solution
attributes, constraints, objectives, variables
-
Field Details
-
Constructor Details
-
DefaultDoubleSolution
@Deprecated public DefaultDoubleSolution(java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Double,java.lang.Double>> bounds, int numberOfObjectives, int numberOfConstraints)Deprecated.UseDefaultDoubleSolution(int, int, List)instead.Constructor -
DefaultDoubleSolution
public DefaultDoubleSolution(int numberOfObjectives, int numberOfConstraints, java.util.List<Bounds<java.lang.Double>> boundsList)Constructor -
DefaultDoubleSolution
@Deprecated public DefaultDoubleSolution(java.util.List<org.apache.commons.lang3.tuple.Pair<java.lang.Double,java.lang.Double>> bounds, int numberOfObjectives)Deprecated.UseDefaultDoubleSolution(int, List)instead.Constructor -
DefaultDoubleSolution
public DefaultDoubleSolution(int numberOfObjectives, java.util.List<Bounds<java.lang.Double>> boundsList)Constructor -
DefaultDoubleSolution
Copy constructor
-
-
Method Details
-
getLowerBound
@Deprecated public java.lang.Double getLowerBound(int index)Deprecated.UsegetBounds(int).getLowerBound()instead.- Specified by:
getLowerBoundin interfaceDoubleSolution
-
getUpperBound
@Deprecated public java.lang.Double getUpperBound(int index)Deprecated.UsegetBounds(int).getUpperBound()instead.- Specified by:
getUpperBoundin interfaceDoubleSolution
-
getBounds
Description copied from interface:DoubleSolutionIt is often the case that we use both bounds together. Searching twice the same index may be counter productive in this case. This methods allows to offer this optimization, although its default implementation just delegates to the separate methods.- Specified by:
getBoundsin interfaceDoubleSolution
-
copy
-