All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class evolution.RandomAccessGenome

java.lang.Object
   |
   +----evolution.RandomAccessGenome

public class RandomAccessGenome
extends Object
implements RandomAccess, Genome
A genome implementation that provides random access to its genes. Uses RandomAccessGenomeStorage to accomplish this.


Variable Index

 o data
My genetic data

Constructor Index

 o RandomAccessGenome(RandomAccessGenomeStorage)
Creates me containing the specified genetic data

Method Index

 o getGene(int)
 o length()
 o mitosis(Genome[], EvolutionParm, RandomGenerator)
Merge the parent genomes to produce a child genome: me.

Variables

 o data
 protected RandomAccessGenomeStorage data
My genetic data

Constructors

 o RandomAccessGenome
 public RandomAccessGenome(RandomAccessGenomeStorage d) throws NilException
Creates me containing the specified genetic data

Throws: NilException
if the argument is nil

Methods

 o mitosis
 public Genome mitosis(Genome parent[],
                       EvolutionParm p,
                       RandomGenerator rg) throws EvolutionException
Merge the parent genomes to produce a child genome: me. Should be static, but Java interfaces cannot contain static methods.

 o getGene
 public Gene getGene(int i) throws EvolutionException
Returns:
the Gene at position i
 o length
 public int length()
Returns:
the number of genes I contain, 0 if my data is nil

All Packages  Class Hierarchy  This Package  Previous  Next  Index