Planting.h

00001 //---------------------------------------------------------------------------
00002 
00003 #ifndef PlantingH
00004 #define PlantingH
00005 //---------------------------------------------------------------------------
00006 #include "BehaviorBase.h"
00007 class clGridBase;
00008 class clPackage;
00009 class clTree;
00010 
00052 class clPlant : virtual public clBehaviorBase {
00053 
00054  public:
00055 
00061  clPlant(clSimManager *p_oSimManager);
00062 
00066  ~clPlant();
00067 
00071  void TimestepCleanup();
00072 
00078  void Action();
00079 
00081  enum spaceType {gridded,  
00082                  random};  
00084  protected:
00085  clTreePopulation *mp_oPop;       
00125  clGridBase *mp_oPlantMasterGrid;
00126 
00152  clGridBase *mp_oPlantEventsGrid;
00153 
00171  clGridBase *mp_oPlantResultsGrid;
00172 
00173  float *mp_fInitialDiam10;       
00176  //These hold the return codes for the data members
00177  short int m_iMasterTimestepCode;   
00178  short int m_iMasterIDCode;         
00179  short int *mp_iAmtPlantCodes;      
00181  short int m_iSpaceTypeCode;        
00182  short int m_iSpacingOrDensityCode; 
00184  short int m_iPlantTimestepCode;    
00185  short int m_iPlantIDCode;          
00187            //"plantresults" grid data members
00188  short int *mp_iPlantedCodes;       
00192  struct stcGridList {
00193      stcGridList *next;      
00194      short int iX, 
00195                iY; 
00196  };
00197 
00205  void GetData(xercesc::DOMDocument *p_oDoc);
00206 
00210  void SetupPlantGrids();
00211 
00221  void ValidatePackages();
00222 
00234 void PlantTrees(clPackage *p_oMasterPackage);
00235 
00251 int AssemblePlantArea(clPackage *p_oMasterPackage, const int &iNumXCells,
00252    const int &iNumYCells, stcGridList *&p_plantArea);
00253 
00254 };
00255 //---------------------------------------------------------------------------
00256 #endif

Generated on Thu Jan 26 13:44:34 2006 for SORTIE Core C++ Documentation by  doxygen 1.4.6-NO