Class BooleanGenotype

All Implemented Interfaces:
Serializable, Cloneable, Iterable<Boolean>, Collection<Boolean>, List<Boolean>, RandomAccess, Genotype, ListGenotype<Boolean>
Direct Known Subclasses:
BooleanMapGenotype

public class BooleanGenotype extends ArrayList<Boolean> implements ListGenotype<Boolean>
The BooleanGenotype consists of Boolean values that can be used as a Genotype.
See Also:
  • Constructor Details

  • Method Details

    • newInstance

      public <G extends Genotype> G newInstance()
      Description copied from interface: Genotype
      Constructs a new (empty) instance of this Genotype.
      Specified by:
      newInstance in interface Genotype
      Type Parameters:
      G - the type of genotype for an implicit cast
      Returns:
      new instance of the genotype
    • init

      public void init(Random random, int n)
      Initialize this genotype with n random values.
      Parameters:
      random - the random number generator
      n - the number of elements in the resulting genotype