org.jgap.gp.impl
Class DefaultProgramCreator
java.lang.Object
org.jgap.gp.impl.DefaultProgramCreator
- All Implemented Interfaces:
- IProgramCreator
public class DefaultProgramCreator
- extends java.lang.Object
- implements IProgramCreator
Used by DefaultPopulationCreator to create GP programs.
- Since:
- 3.2.1
|
Method Summary |
IGPProgram |
create(GPConfiguration a_conf,
int a_programIndex,
java.lang.Class[] a_types,
java.lang.Class[][] a_argTypes,
CommandGene[][] a_nodeSets,
int[] a_minDepths,
int[] a_maxDepths,
int a_maxNodes,
int a_depth,
boolean a_grow,
int a_tries,
boolean[] a_fullModeAllowed)
Initializes the given population by adding new individuals to it. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DefaultProgramCreator
public DefaultProgramCreator()
create
public IGPProgram create(GPConfiguration a_conf,
int a_programIndex,
java.lang.Class[] a_types,
java.lang.Class[][] a_argTypes,
CommandGene[][] a_nodeSets,
int[] a_minDepths,
int[] a_maxDepths,
int a_maxNodes,
int a_depth,
boolean a_grow,
int a_tries,
boolean[] a_fullModeAllowed)
throws InvalidConfigurationException
- Description copied from interface:
IProgramCreator
- Initializes the given population by adding new individuals to it.
- Specified by:
create in interface IProgramCreator
- Parameters:
a_conf - the configuration to usea_programIndex - index of the current program in the population,
starting with 0a_types - Class[]a_argTypes - Class[][]a_nodeSets - CommandGene[][]a_minDepths - int[]a_maxDepths - int[]a_maxNodes - inta_depth - the required depth of the programa_grow - true: use grow mode, false: use full modea_tries - maximum number of tries allowed to produce a valid programa_fullModeAllowed - boolean[]
- Returns:
- the newly created program
- Throws:
InvalidConfigurationException - in case of any error