GLBaseCrossover Class Reference

#include <GLBaseCrossover.h>

Inheritance diagram for GLBaseCrossover:

GLCrossoverOnePoint GLCrossoverTwoPoints GLCrossoverVectorKeepMatching< T >

List of all members.

Public Member Functions

 GLBaseCrossover ()
virtual ~GLBaseCrossover ()
virtual void makeOffsprings (const vector< GLBaseOrganism * > &parents, vector< GLBaseOrganism * > &children)=0
virtual void reset ()


Detailed Description

Base class for crossover algorithm.

Definition at line 8 of file GLBaseCrossover.h.


Constructor & Destructor Documentation

GLBaseCrossover::GLBaseCrossover (  )  [inline]

Simple constructor.

Definition at line 14 of file GLBaseCrossover.h.

virtual GLBaseCrossover::~GLBaseCrossover (  )  [inline, virtual]

Simple destructor, destroys everything.

Definition at line 18 of file GLBaseCrossover.h.


Member Function Documentation

virtual void GLBaseCrossover::makeOffsprings ( const vector< GLBaseOrganism * > &  parents,
vector< GLBaseOrganism * > &  children 
) [pure virtual]

Creates an offspring from the vector of parents. Note, that the number of parents can be arbitrary, although normally 2 parents are used.

Parameters:
parents vector of parents.
children vector of new organisms obtained from parents. Previous content will not be preserved.

Implemented in GLCrossoverOnePoint, GLCrossoverTwoPoints, and GLCrossoverVectorKeepMatching< T >.

virtual void GLBaseCrossover::reset (  )  [inline, virtual]

Resets the crossover (e.g. sets counter, if any, to zero etc.).

Definition at line 33 of file GLBaseCrossover.h.


The documentation for this class was generated from the following file:

Generated on Sat Jun 13 13:58:05 2009 for GenLib by  doxygen 1.5.9