TraitPrototype Class Reference

TTrait setter. More...

#include <ttrait.h>

Inheritance diagram for TraitPrototype:

Inheritance graph
[legend]
Collaboration diagram for TraitPrototype:

Collaboration graph
[legend]

List of all members.

Public Member Functions

virtual void init ()=0
 Inits the parameters, called by IndFactory::makePrototype().
virtual TTraithatch ()=0
 Creates the trait of which it is the prototype, called by IndFactory::makePrototype().
virtual TraitPrototypeclone ()=0
 Returns a copy of itself.
virtual trait_t get_type () const =0
 Type accessor.
virtual void set_index (int idx)
 Sets the traits index.
virtual int get_index ()
 Index getter.

Protected Attributes

int _index
 The trait index in the Individual traits table.


Detailed Description

TTrait setter.

Encapsulates the methods to set the traits parameters and to generate traits. Also stores the posistion of the trait in the individuals trait table. This class manages the file and stat handlers through its inheritance of the SimComponent interface.

Definition at line 118 of file ttrait.h.


Member Function Documentation

virtual TraitPrototype* TraitPrototype::clone (  )  [pure virtual]

Returns a copy of itself.

Note: calls the copy constructor and only copy the parameters state.

Implemented in TProtoDeletMutations_bitstring, TProtoDispersal, TProtoNeutralGenes, and TProtoWolbachia.

virtual int TraitPrototype::get_index (  )  [inline, virtual]

Index getter.

Definition at line 138 of file ttrait.h.

00138 {return _index;}

virtual trait_t TraitPrototype::get_type (  )  const [pure virtual]

Type accessor.

Returns:
the trait's type

Implemented in TProtoDeletMutations_bitstring, TProtoDispersal, TProtoNeutralGenes, and TProtoWolbachia.

virtual TTrait* TraitPrototype::hatch (  )  [pure virtual]

Creates the trait of which it is the prototype, called by IndFactory::makePrototype().

Implemented in TProtoDeletMutations_bitstring, TProtoDispersal, TProtoNeutralGenes, and TProtoWolbachia.

virtual void TraitPrototype::init (  )  [pure virtual]

virtual void TraitPrototype::set_index ( int  idx  )  [inline, virtual]

Sets the traits index.

Called by IndFactory::makePrototype().

Definition at line 136 of file ttrait.h.

00136 {_index = idx;}


Member Data Documentation

int TraitPrototype::_index [protected]

The trait index in the Individual traits table.

Definition at line 122 of file ttrait.h.

Referenced by get_index(), and set_index().


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

Generated for Nemo v2.1.2 by  doxygen 1.5.8 -- Nemo is hosted by  SourceForge.net Logo