clDisperseBase Class Reference

Disperse base - Version 1.0. More...

#include <DisperseBase.h>

Inheritance diagram for clDisperseBase:

clBehaviorBase clWorkerBase clGridBasedSpatialDisperse clNonSpatialDispersal clSpatialDispersal clAnisotropicDisperse clIsotropicDisperse List of all members.

Public Member Functions

 clDisperseBase (clSimManager *p_oSimManager)
 Constructor.
 ~clDisperseBase ()
 Destroys common objects.
void Action ()
 Performs all disperse calculations.
void TimestepCleanup ()
 Resets all values in the seed grid to 0 and sets the static m_bUpdatedGapStatus to false if this is a hooked object.

Protected Types

enum  function { weibull, lognormal }
 What PDF is used by a species. More...
enum  cover { gap, canopy }
 Cover status. More...

Protected Member Functions

void GetData (xercesc::DOMDocument *p_oDoc)
 Triggers all disperse setup if an object is hooked.
virtual void DoShellSetup (xercesc::DOMDocument *p_oDoc)=0
 Setup for a descendent class.
virtual void AddSeeds ()=0
 Performs disperse and adds seeds to seed grid.
void SetUpBase ()
 Does disperse base setup.

Protected Attributes

bool m_bHooked
 Wwhether or not this shell object is hooked to clDisperseOrg.

Static Protected Attributes

static clDisperseOrgmp_oDisperseOrg
 clDisperseOrg object - this pointer is held in common by all shells
static clGridBasemp_oSeedGrid
 Seed grid.
static float * mp_fDbhForReproduction
 Array of species with each one's dbh for reproduction - sized TOTAL NUMBER OF SPECIES.
static short int * mp_iNumSeedsCode
 Data member codes for "dispersed seeds" grid for "seeds_x" data member.
static short int m_iGapCountCode
 Data member code - for counting trees for gap status.
static short int m_iIsGapCode
 Data member code for substrate grid for gap status.
static short int m_iTotalSpecies
 Total number of species.
static bool m_bUpdatedGapStatus
 A flag indicating whether or not the gap status of the seed grid has been updated this timestep.
static bool m_bIsStochastic
 Whether dispersal is stochastic (true) or deterministic (false).

Friends

class clDisperseOrg

Detailed Description

Disperse base - Version 1.0.

This is the base class for disperse behaviors. This holds common data.

Copyright 2003 Charles D. Canham.

Author:
Lora E. Murphy

Edit history:
-----------------
April 28, 2004 - Submitted as beta (LEM)


Member Enumeration Documentation

enum clDisperseBase::cover [protected]
 

Cover status.

Enumerator:
gap  Gap cover.
canopy  Canopy cover.

enum clDisperseBase::function [protected]
 

What PDF is used by a species.

Enumerator:
weibull  Weibull function type.
lognormal  Lognormal function type.


Constructor & Destructor Documentation

clDisperseBase::clDisperseBase clSimManager p_oSimManager  ) 
 

Constructor.

Sets the hook flag.


Member Function Documentation

void clDisperseBase::Action  )  [virtual]
 

Performs all disperse calculations.

This will be the same for all descendent classes - they do not need to override. If a particular object is hooked, it calls the disperse org object's DoDisperse. Otherwise it does nothing.

Reimplemented from clBehaviorBase.

virtual void clDisperseBase::DoShellSetup xercesc::DOMDocument *  p_oDoc  )  [protected, pure virtual]
 

Setup for a descendent class.

If a descendent class has specific setup needs, it can overload this function.

Parameters:
p_oDoc DOM tree of parsed input file.

Implemented in clGridBasedSpatialDisperse, clNonSpatialDispersal, and clSpatialDispersal.

void clDisperseBase::GetData xercesc::DOMDocument *  p_oDoc  )  [protected, virtual]
 

Triggers all disperse setup if an object is hooked.

This will be the same for all descendent classes. If a particular object is hooked, it calls the disperse org object's DoSetup() function, which calls the function DoShellSetup() - if a descendent class has specific setup needs, it can overload that function.

Parameters:
p_oDoc DOM tree of parsed input file.

Implements clWorkerBase.

void clDisperseBase::SetUpBase  )  [protected]
 

Does disperse base setup.

Sets up the "dispersed_seeds" grid, if the static pointer is NULL, and declares mp_fDbhForReproduction.


Member Data Documentation

bool clDisperseBase::m_bHooked [protected]
 

Wwhether or not this shell object is hooked to clDisperseOrg.

clDisperseOrg will set this flag.

bool clDisperseBase::m_bUpdatedGapStatus [static, protected]
 

A flag indicating whether or not the gap status of the seed grid has been updated this timestep.

This will be reset to false during the timestep cleanup.

short int* clDisperseBase::mp_iNumSeedsCode [static, protected]
 

Data member codes for "dispersed seeds" grid for "seeds_x" data member.

Array size is # species.

clGridBase* clDisperseBase::mp_oSeedGrid [static, protected]
 

Seed grid.

This is the grid which contains the numbers and locations of seeds produced by all parent trees. The resolution defaults to the standard grid default if it is not set by a grid map or grid map header.

The grid's name is "Dispersed Seeds". The grid is static, because multiple instances of this object could be instantiated to handle different dispersal situations.

Data members:
Member name Data type Description
seeds_x float Number of seeds for each tree species. "x" = species number. There is no check to make sure that each species actually uses disperse.
Is Gap bool Gap status of each grid cell.
count int Count of reproductively mature trees that use disperse. This number is used to determine gap status.


The documentation for this class was generated from the following file:
Generated on Mon Mar 27 12:51:11 2006 for SORTIE Core C++ Documentation by  doxygen 1.4.6-NO