Evocosm - A C++ Framework for Evolutionary Computing

Main Index

Created by Scott Robert Ladd at Coyote Gulch Productions.


Public Member Functions

libevocosm::listener< OrganismType > Class Template Reference

An abstract interface defining a listener. More...

#include <listener.h>

Inheritance diagram for libevocosm::listener< OrganismType >:
libevocosm::null_listener< OrganismType >

List of all members.

Public Member Functions


Detailed Description

template<typename OrganismType>
class libevocosm::listener< OrganismType >

Evocosm reports its activities through a listener object derived from this abstract class. Some events state that a given event has occurred (e.g., the beginning of a new generation), while others provide text for display.


Member Function Documentation

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::ping_fitness_test_begin ( const OrganismType &  a_organism_number) [pure virtual]

Ping that fitness testing of an organism begins.

Parameters:
a_organism_numberOne-based number of the organism

Implemented in libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::ping_fitness_test_end ( const OrganismType &  a_organism_number) [pure virtual]

Ping that processing a generation has ended.

Parameters:
a_organism_numberOne-based number of the organism

Implemented in libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::ping_generation_begin ( const vector< OrganismType > &  a_population,
size_t  a_iteration 
) [pure virtual]

Ping that processing a generation begins.

Parameters:
a_populationPopulation before this generation's evolution
a_iterationOne-based number of the generation begun

Implemented in libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::ping_generation_end ( const vector< OrganismType > &  a_population,
size_t  a_iteration 
) [pure virtual]

Ping that processing a generation has ended.

Parameters:
a_populationPopulation for which processing has ended
a_iterationOne-based number of the generation ended

Implemented in libevocosm::function_listener, libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::report ( const std::string &  a_text) [pure virtual]

This event provide status text specific to a given type of evocosm. The base evocosm class does not call this function. The intention is that this function will be called from classes derived from evocosm to report progress, statistics, or other useful information.

Parameters:
a_textApplication-specific text

Implemented in libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::report_error ( const std::string &  a_text) [pure virtual]

This event provides error text specific to a given type of evocosm. The base evocosm class does not call this function. The intention is that this function will be called from classes derived from evocosm to report problems.

Parameters:
a_textApplication-specific error text

Implemented in libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.

template<typename OrganismType>
virtual void libevocosm::listener< OrganismType >::run_complete ( const vector< OrganismType > &  a_population) [pure virtual]

Invoked when an evocosm finishes all processing. This way God can rest on the seventh day.

Implemented in libevocosm::null_listener< OrganismType >, and libevocosm::null_listener< function_solution >.


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

© 2011 Scott Robert Ladd. All rights reserved.
HTML documentation generated by Dimitri van Heesch's excellent Doxygen tool.