GenomeType
- Type of genome used to represent a single element in the
genetic population, such as a Vector, for example@CodeReview(reviewer="Kevin R. Dixon",date="2008-07-23",changesNeeded=false,comments={"This class still has an open task... I suspect this is due to a lack of interest.","Moved previous code review as CodeReview annotation.","Looks fine."}) @CodeReview(reviewer="Justin Basilico",date="2006-10-04",changesNeeded=false,comments={"Minor changes made.","Looks fine otherwise."}) public class MultiReproducer<GenomeType> extends java.lang.Object implements Reproducer<GenomeType>
Constructor and Description |
---|
MultiReproducer(java.util.Collection<Reproducer<GenomeType>> reproducers)
Creates a new instance of MultiReproducer.
|
Modifier and Type | Method and Description |
---|---|
java.util.Collection<Reproducer<GenomeType>> |
getReproducers()
Gets the reproducers to use for reproducing.
|
java.util.ArrayList<GenomeType> |
reproduce(java.util.Collection<EvaluatedGenome<GenomeType>> genomes)
Applies the supplied reproducers to the population of genomes.
|
void |
setReproducers(java.util.Collection<Reproducer<GenomeType>> reproducers)
Sets the reproducers to use for reproducing.
|
public MultiReproducer(java.util.Collection<Reproducer<GenomeType>> reproducers)
reproducers
- The reproducers to use.public java.util.ArrayList<GenomeType> reproduce(java.util.Collection<EvaluatedGenome<GenomeType>> genomes)
reproduce
in interface Reproducer<GenomeType>
genomes
- The current population of genomes along with their
associated costs.public java.util.Collection<Reproducer<GenomeType>> getReproducers()
public void setReproducers(java.util.Collection<Reproducer<GenomeType>> reproducers)
reproducers
- The new reproducers.