Class PropertiesProblems

java.lang.Object
org.moeaframework.core.spi.ProblemProvider
org.moeaframework.problem.PropertiesProblems

public class PropertiesProblems extends ProblemProvider
Legacy problem provider that loads problems defined in "moeaframework.properties". For example, we could add the following to the properties file:
   org.moeaframework.problem.TestLZ1.class = org.moeaframework.problem.LZ.LZ1
   org.moeaframework.problem.TestLZ1.referenceSet = ./pf/LZ09_F1.pf
 
And then instantiate the problem with:
 
   ProblemFactory.getInstance().getProblem("TestLZ1");
 
Defining problems this way is no longer recommended. Instead, we recommend using a RegisteredProblemProvider to register new problems with this framework.
  • Constructor Details

    • PropertiesProblems

      public PropertiesProblems()
      Constructs the problem provider for problems enumerated in "moeaframework.properties".
  • Method Details

    • getProblem

      public Problem getProblem(String name)
      Description copied from class: ProblemProvider
      Returns the problem with the specified name, or null if this provider does not support the problem.
      Specified by:
      getProblem in class ProblemProvider
      Parameters:
      name - the problem name
      Returns:
      the problem with the specified name, or null if this provider does not support the problem
    • getReferenceSet

      public NondominatedPopulation getReferenceSet(String name)
      Description copied from class: ProblemProvider
      Returns the reference set for the specified problem, or null if this provider does not support the problem or no reference set is available.
      Specified by:
      getReferenceSet in class ProblemProvider
      Parameters:
      name - the problem name
      Returns:
      the reference set for the specified problem, or null if this provider does not support the problem or no reference set is available