Class FakeIntegerProblem
java.lang.Object
org.uma.jmetal.problem.integerproblem.impl.AbstractIntegerProblem
org.uma.jmetal.problem.integerproblem.impl.FakeIntegerProblem
- All Implemented Interfaces:
Serializable,IntegerProblem,Problem<IntegerSolution>
Fake implementation of
IntegerProblem. Intended to be used in unit tests.- See Also:
-
Field Summary
Fields inherited from class org.uma.jmetal.problem.integerproblem.impl.AbstractIntegerProblem
bounds, name, numberOfConstraints, numberOfObjectives -
Constructor Summary
ConstructorsConstructorDescriptionFakeIntegerProblem(int numberOfVariables, int numberOfObjectives, int numberOfConstraints) Constructor with default bounds [0, 10] for all variablesFakeIntegerProblem(int numberOfVariables, int numberOfObjectives, int numberOfConstraints, int lowerBound, int upperBound) Constructor with custom bounds for all variables -
Method Summary
Modifier and TypeMethodDescriptionevaluate(IntegerSolution solution) This method receives a solution, evaluates it, and returns the evaluated solution.Methods inherited from class org.uma.jmetal.problem.integerproblem.impl.AbstractIntegerProblem
createSolution, name, name, numberOfConstraints, numberOfConstraints, numberOfObjectives, numberOfObjectives, numberOfVariables, variableBounds, variableBounds
-
Constructor Details
-
FakeIntegerProblem
public FakeIntegerProblem(int numberOfVariables, int numberOfObjectives, int numberOfConstraints) Constructor with default bounds [0, 10] for all variables- Parameters:
numberOfVariables- Number of variablesnumberOfObjectives- Number of objectivesnumberOfConstraints- Number of constraints
-
FakeIntegerProblem
public FakeIntegerProblem(int numberOfVariables, int numberOfObjectives, int numberOfConstraints, int lowerBound, int upperBound) Constructor with custom bounds for all variables- Parameters:
numberOfVariables- Number of variablesnumberOfObjectives- Number of objectivesnumberOfConstraints- Number of constraintslowerBound- Lower bound for all variablesupperBound- Upper bound for all variables
-
FakeIntegerProblem
public FakeIntegerProblem()
-
-
Method Details
-
evaluate
Description copied from interface:ProblemThis method receives a solution, evaluates it, and returns the evaluated solution.- Parameters:
solution-- Returns:
-