Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

InterGene Class Reference

A reference gene. More...

#include <genes.h>

Inheritance diagram for InterGene:

Gene Genstruct List of all members.

Public Methods

 InterGene (const GeneticID &name=NULL, const GeneticID &trg=NULL)
virtual void init ()
virtual Genstructreplicate () const
virtual void copy (const Genstruct &other)
virtual bool execute (const GeneticMsg &msg) const
virtual void print (TextOStream &out) const
virtual bool pointMutate (const MutationRate &k)

Detailed Description

A reference gene.

Executing this gene automatically executes another gene.

Definition at line 771 of file genes.h.


Constructor & Destructor Documentation

InterGene const GeneticID &    name = NULL,
const GeneticID &    trg = NULL
[inline]
 

Standard constructor.

Parameters:
name  Name of the gene.
name  trg Name of the target gene which this gene acts as a reference to.

Definition at line 780 of file genes.h.

Referenced by replicate().


Member Function Documentation

void copy const Genstruct   other [virtual]
 

Implementation for Genstruct.

Reimplemented from Gene.

Definition at line 589 of file genes.cc.

References Genstruct::copyGenstr().

bool execute const GeneticMsg   msg const [virtual]
 

Transmits a sad order to execute a gene.

The receiver of the message reads in the upper left corner of the message. It should then execute itself. It's good that objects don't have feelings. (Hmm, they don't?)

Reimplemented from Genstruct.

Definition at line 585 of file genes.cc.

References Individual::execute(), and GeneticMsg::host.

virtual void init   [inline, virtual]
 

Implementation for Genstruct.

The initialization command is not passed through to the referred gene.

Reimplemented from Genstruct.

Definition at line 789 of file genes.h.

virtual bool pointMutate const MutationRate   k [inline, virtual]
 

Mutates the structure.

Parameters:
r  Mutation rate coefficients.
Returns:
TRUE if an actual mutation (change on genotype) has occurred.

Reimplemented from Genstruct.

Definition at line 794 of file genes.h.

void print TextOStream &    out const [virtual]
 

Recursively prints the genome to the given stream.

This is most cool.

Reimplemented from Genstruct.

Definition at line 594 of file genes.cc.

References Genstruct::id.

virtual Genstruct* replicate   const [inline, virtual]
 

Clones a copy of self, RECURSIVELY.

It's funny how simple reproduction is nowadays.

Reimplemented from Genstruct.

Definition at line 790 of file genes.h.

References InterGene().


The documentation for this class was generated from the following files:
Generated on Thu Feb 10 20:12:01 2005 for NeHeP by doxygen1.2.18