SORTIE Core C++ Documentation
Public Member Functions | Protected Member Functions | Protected Attributes | Private Member Functions | List of all members
clGhostTreePopulation Class Reference

GHOST TREE POPULATION CLASS - Version 1. More...

#include <GhostTreePopulation.h>

Inheritance diagram for clGhostTreePopulation:
clPopulationBase clWorkerBase

Public Member Functions

 ~clGhostTreePopulation ()
 Destructor.
 
 clGhostTreePopulation (clSimManager *p_oSimManager)
 Constructor.
 
void AddTree (clTree *p_oTree, deadCode iDeadReasonCode)
 Creates a copy of a tree and adds it to this population.
 
clDeadTreeGetFirstTree ()
 Gets the first tree in the linked list.
 
void GetData (xercesc::DOMDocument *p_oDoc)
 Not needed.
 
- Public Member Functions inherited from clPopulationBase
virtual void DoDataUpdates ()
 Performs cleanup between behavior action calls.
 
virtual ~clPopulationBase ()
 Destructor.
 
 clPopulationBase (clSimManager *p_oSimManager)
 Constructor.
 
- Public Member Functions inherited from clWorkerBase
 clWorkerBase (clSimManager *p_oSimManager)
 Constructor.
 
virtual ~clWorkerBase ()
 Destructor.
 
std::string GetName ()
 Gets the object's namestring.
 
clSimManagerGetSimManager ()
 
void DoObjectSetup (xercesc::DOMDocument *p_oDoc, fileType iFileType)
 Triggers the setup process.
 
virtual void EndOfRunCleanup ()
 Performs any necessary cleanup operations at the end of a run.
 

Protected Member Functions

void TimestepCleanup ()
 Deletes all trees.
 

Protected Attributes

clDeadTreemp_oTrees
 Linked list of dead trees.
 

Private Member Functions

 clGhostTreePopulation (const clGhostTreePopulation &oldPop)
 Copy constructor.
 

Detailed Description

GHOST TREE POPULATION CLASS - Version 1.

This holds dead trees. They are held for a single timestep then eliminated at the end of the timestep. This holds seedlings through snags. Stumps are not kept.

The trees are not sorted, just held in a simple linked list.

Copyright 2010 Charles D. Canham.

Author
Lora E. Murphy


Edit history:
--------------—
December 21, 2010 - Created (LEM)

Constructor & Destructor Documentation

clGhostTreePopulation::clGhostTreePopulation ( const clGhostTreePopulation oldPop)
private

Copy constructor.

Off limits! It's too much to try to copy all the trees, and too dangerous to allow two objects running around with pointers to the same trees.

clGhostTreePopulation::~clGhostTreePopulation ( )

Destructor.

clGhostTreePopulation::clGhostTreePopulation ( clSimManager p_oSimManager)

Constructor.

Parameters
p_oSimManagerSim Manager object.

Member Function Documentation

void clGhostTreePopulation::AddTree ( clTree p_oTree,
deadCode  iDeadReasonCode 
)

Creates a copy of a tree and adds it to this population.

The original tree is not touched or removed from the old population.

Parameters
p_oTreetree to copy and add.
iDeadReasonCodeWhy the tree died.
void clGhostTreePopulation::GetData ( xercesc::DOMDocument *  p_oDoc)
inlinevirtual

Not needed.

Parameters
p_oDocDOM tree of parsed input file.

Implements clWorkerBase.

clDeadTree* clGhostTreePopulation::GetFirstTree ( )
inline

Gets the first tree in the linked list.

Returns
First tree in the list, or NULL if there are no trees.
void clGhostTreePopulation::TimestepCleanup ( )
protectedvirtual

Deletes all trees.

Reimplemented from clWorkerBase.

Member Data Documentation

clDeadTree* clGhostTreePopulation::mp_oTrees
protected

Linked list of dead trees.


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