#include <TreeRemover.h>
Public Member Functions | |
clTreeRemover (clSimManager *p_oSimManager) | |
Constructor. | |
~clTreeRemover () | |
Destructor. | |
void | Action () |
Does all the tree killin'. | |
void | GetData (xercesc::DOMDocument *p_oDoc) |
Gets the data member codes for the "dead" data member. | |
Protected Attributes | |
clTreePopulation * | mp_oPop |
Stashed pointer to avoid having to keep getting it. | |
short int ** | mp_iDeadCodes |
Return codes for the "dead" tree int data member variable. | |
short int | m_iNumTotalSpecies |
Total number of species - for destructor. |
This behavior will remove all trees that have been marked for death by mortality. If a tree has a non-not dead value in its "dead" data member, this will direct it to be removed from the tree population by calling clTreePopulation::KillTree(). The reason code is that which is set in "dead".
If this is applied to any species/type combo that does not have "dead" registered, an error will be thrown during setup.
The namestring and parameter call string for this behavior are both "removedead".
Copyright 2003 Charles D. Canham.
clTreeRemover::clTreeRemover | ( | clSimManager * | p_oSimManager | ) |
Constructor.
p_oSimManager | Sim Manager object. |
clTreeRemover::~clTreeRemover | ( | ) |
Destructor.
void clTreeRemover::Action | ( | ) | [virtual] |
Does all the tree killin'.
This goes through all trees in the tree population to which this behavior is applied, and if any have a non-notdead value in their "dead" data member, they are passed to clTreePopulation::KillTree() with that reason code.
Reimplemented from clBehaviorBase.
void clTreeRemover::GetData | ( | xercesc::DOMDocument * | p_oDoc | ) | [virtual] |
Gets the data member codes for the "dead" data member.
p_oDoc | DOM tree of parsed input file. |
modelErr | if a tree type/species combo to which this behavior is applied has no "dead" code. |
Implements clWorkerBase.
clTreePopulation* clTreeRemover::mp_oPop [protected] |
Stashed pointer to avoid having to keep getting it.
short int** clTreeRemover::mp_iDeadCodes [protected] |
Return codes for the "dead" tree int data member variable.
Array size is species by type (even if not every species and type is represented)
short int clTreeRemover::m_iNumTotalSpecies [protected] |
Total number of species - for destructor.