Back to Top page.

EGTSelection< TP > Class Template Reference

Abstract base class template for selection operations. More...

#include <EGTSelection.h>

Inheritance diagram for EGTSelection< TP >:

Inheritance graph
[legend]
List of all members.

Public Types

typedef TP Pop
typedef Pop::Graph Graph
typedef EGTVector< const Graph * > Graphs

Public Methods

virtual ~EGTSelection ()
 Destructor.

virtual void Selection (const Pop &src, Graphs &dest, UInt uCount)=0
 Performs selection operations to the Population.

virtual void Selection (const Pop &src, Pop &dest, UInt uCount)=0
 Performs selection operations to the Population.


Detailed Description

template<class TP>
class EGTSelection< TP >

Abstract base class template for selection operations.

A selection operation is used to select a Graph from the Population.
This class is a pure virtual (abstract) class and cannot be instantiated.
To make your derived class, you must define your own Selection function and Fill function.
It is assumed that <TP> is a subclass of EGTPopulation.


Member Typedef Documentation

template<class TP>
typedef Pop::Graph EGTSelection< TP >::Graph
 

Reimplemented in EGTElitistSel< TP >, and EGTRouletteSel< TP >.

template<class TP>
typedef EGTVector<const Graph*> EGTSelection< TP >::Graphs
 

Reimplemented in EGTElitistSel< TP >, and EGTRouletteSel< TP >.

template<class TP>
typedef TP EGTSelection< TP >::Pop
 

Reimplemented in EGTElitistSel< TP >, and EGTRouletteSel< TP >.


Constructor & Destructor Documentation

template<class TP>
virtual EGTSelection< TP >::~EGTSelection   [inline, virtual]
 

Destructor.


Member Function Documentation

template<class TP>
virtual void EGTSelection< TP >::Selection const Pop   src,
Pop   dest,
UInt    uCount
[pure virtual]
 

Performs selection operations to the Population.

This function is pure virtual and cannot be instantiated, so it should be implemented in the derived class.

Parameters:
src  [in] Population to be performed by the selection operations
dest  [out] Population where the selected Graphs are stored
uCount  [in] Number of Graphs to be selected by the selection operations

Implemented in EGTElitistSel< TP >, and EGTRouletteSel< TP >.

template<class TP>
virtual void EGTSelection< TP >::Selection const Pop   src,
Graphs   dest,
UInt    uCount
[pure virtual]
 

Performs selection operations to the Population.

This function is pure virtual and cannot be instantiated, so it should be implemented in the derived class.

Parameters:
src  [in] Population to be performed by the selection operations
dest  [out] Array of Graphs to be selected by the selection operations
uCount  [in] Number of Graphs to be selected by the selection operations

Implemented in EGTElitistSel< TP >, and EGTRouletteSel< TP >.


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