SORTIE C++ Test Documentation
Functions
TestInsectInfestation.h File Reference
#include <fstream>

Functions

const char * WriteInsectInfestationXMLNormalFile (int iNumYrsTimestep, int iTSStart, int iTSEnd)
 Writes the parameter file for TestNormalProcessingX(). More...
 
const char * WriteInsectInfestationXMLFile3 ()
 Writes the parameter file for TestNormalProcessing3(). More...
 
const char * WriteInsectInfestationXMLErrorFile1 ()
 Writes an error file where the minimum DBH is negative. More...
 
const char * WriteInsectInfestationXMLErrorFile2 ()
 Writes an error file where the insect infestation behavior is applied to seedlings. More...
 
const char * WriteInsectInfestationXMLErrorFile3 ()
 Writes an error file where the timestep to start infestation is negative. More...
 
const char * WriteInsectInfestationXMLErrorFile4 ()
 Writes an error file where the intercept is not between 0 and 1. More...
 
const char * WriteInsectInfestationXMLErrorFile5 ()
 Writes an error file where max infestation is not between 0 and 1. More...
 
const char * WriteInsectInfestationXMLErrorFile6 ()
 Writes an error file where X0 = zero. More...
 
void WriteInsectInfestationErrorCommonStuff (std::fstream &oOut)
 Writes common portions of the test parameter files. More...
 
void GetTreeCount1Yr (clTreePopulation *p_oPop, long *p_iTotal, long *p_iInfested, bool bNoInfestation)
 Counts trees. More...
 
void GetTreeCount3Yrs (clTreePopulation *p_oPop, long *p_iTotal, long *p_iInfested, bool bNoInfestation)
 Counts trees. More...
 

Function Documentation

◆ GetTreeCount1Yr()

void GetTreeCount1Yr ( clTreePopulation *  p_oPop,
long *  p_iTotal,
long *  p_iInfested,
bool  bNoInfestation 
)

Counts trees.

Parameters
p_oPopTree population
p_iTotalTotal trees per species, sized 5.
p_iInfestedInfested trees per species, sized 5.
bNoInfestationIf true, there will be no checking of the years infested value.

◆ GetTreeCount3Yrs()

void GetTreeCount3Yrs ( clTreePopulation *  p_oPop,
long *  p_iTotal,
long *  p_iInfested,
bool  bNoInfestation 
)

Counts trees.

Parameters
p_oPopTree population
p_iTotalTotal trees per species, sized 5.
p_iInfestedInfested trees per species, sized 5.
bNoInfestationIf true, there will be no checking of the years infested value.

◆ WriteInsectInfestationErrorCommonStuff()

void WriteInsectInfestationErrorCommonStuff ( std::fstream &  oOut)

Writes common portions of the test parameter files.

Parameters
oOutFile stream to write to.

◆ WriteInsectInfestationXMLErrorFile1()

const char* WriteInsectInfestationXMLErrorFile1 ( )

Writes an error file where the minimum DBH is negative.

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLErrorFile2()

const char* WriteInsectInfestationXMLErrorFile2 ( )

Writes an error file where the insect infestation behavior is applied to seedlings.

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLErrorFile3()

const char* WriteInsectInfestationXMLErrorFile3 ( )

Writes an error file where the timestep to start infestation is negative.

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLErrorFile4()

const char* WriteInsectInfestationXMLErrorFile4 ( )

Writes an error file where the intercept is not between 0 and 1.

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLErrorFile5()

const char* WriteInsectInfestationXMLErrorFile5 ( )

Writes an error file where max infestation is not between 0 and 1.

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLErrorFile6()

const char* WriteInsectInfestationXMLErrorFile6 ( )

Writes an error file where X0 = zero.

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLFile3()

const char* WriteInsectInfestationXMLFile3 ( )

Writes the parameter file for TestNormalProcessing3().

Returns
File name of the freshly written parameter file.

◆ WriteInsectInfestationXMLNormalFile()

const char* WriteInsectInfestationXMLNormalFile ( int  iNumYrsTimestep,
int  iTSStart,
int  iTSEnd 
)

Writes the parameter file for TestNormalProcessingX().

Parameters
iNumYrsTimestepNumber of years per timestep.
iTSStartTimestep to start infection.
iTSEndTimestep to end infection. If it is 0, it won't be written at all (to check backwards compatibility).
Returns
File name of the freshly written parameter file.