SORTIE Java Interface  1
Public Member Functions | Protected Attributes | List of all members
sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation Class Reference

Corresponds to the clFuncResponseSeedPredation class. More...

Inheritance diagram for sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation:
sortie.data.funcgroups.Behavior

Public Member Functions

 FuncResponseSeedPredation (GUIManager oManager, BehaviorTypeBase oParent, String sDescriptor, String sParFileTag, String sXMLRootString) throws ModelException
 Constructor. More...
 
void validateData (TreePopulation oPop) throws ModelException
 Validates the dataset if seed predation is enabled. More...
 
- Public Member Functions inherited from sortie.data.funcgroups.Behavior
GUIManager getGUIManager ()
 
 Behavior (GUIManager oManager, BehaviorTypeBase oParent, String sDescriptor, String sParFileTag, String sXMLRootString, String sHelpFileString)
 Constructor. More...
 
abstract void validateData (TreePopulation oPop) throws ModelException
 Override this to implement data checking. More...
 
void callSetupDialog (JDialog jParent, MainWindow oMain)
 Override this to call a specific setup dialog for this behavior. More...
 
int getNumberOfDataObjects ()
 Gets the number of managed data objects. More...
 
ModelData getDataObject (int iInd)
 Gets the managed data object at a particular index. More...
 
void validate () throws ModelException
 Behavior performs an internal check to make sure its settings are consistent and logical. More...
 
void setListPosition (int iListPosition) throws ModelException
 Sets the behavior list position. More...
 
int getListPosition ()
 Gets the behavior list position. More...
 
String getXMLParametersRoot ()
 Gets the XML parameter root string. More...
 
int getNumberNewDataMembers ()
 
DataMember getNewTreeDataMember (int iIndex) throws ModelException
 
void setCanApplyTo (int iType, boolean bCanApply)
 Sets whether this behavior can apply to a given tree type. More...
 
String getParameterFileBehaviorName ()
 Gets the parameter file name for this behavior. More...
 
double getVersion ()
 Gets behavior's parameter file version. More...
 
double getMinimumVersion ()
 Gets behavior's parameter file minimum version. More...
 
String getDescriptor ()
 Gets the descriptor string. More...
 
String getHelpFileString ()
 Gets the help file UD. More...
 
void setDescriptor (String s)
 Sets the descriptor string. More...
 
int getNumberOfCombos ()
 Gets the number of species/type combos to which this behavior applies. More...
 
int getNumberOfGrids ()
 Gets the number of grids to which this behavior applies. More...
 
void deleteSpeciesTypeCombo (int iIndex) throws ModelException
 Deletes the SpeciesTypeCombo at the given index. More...
 
void deleteSpeciesTypeCombo (SpeciesTypeCombo oCombo) throws ModelException
 Deletes a SpeciesTypeCombo. More...
 
void clearSpeciesTypeCombos ()
 Empties the species/type combo list. More...
 
SpeciesTypeCombo getSpeciesTypeCombo (int iIndex) throws ModelException
 Returns the SpeciesTypeCombo at the given index of the species/type combo list. More...
 
Grid getGrid (int iIndex) throws ModelException
 Returns the Grid at the given index of the grid applies to list. More...
 
ModelData getRequiredData (int iIndex)
 Returns the required data object at a given index. More...
 
int getNumberOfRequiredDataObjects ()
 Gets the number of required data objects for this behavior. More...
 
void addSpeciesTypeCombo (SpeciesTypeCombo oCombo) throws ModelException
 Adds a new species/type combo to the list to which this behavior applies. More...
 
void addGrid (Grid oGrid, boolean bReplace)
 Adds a new Grid to the list to which this behavior applies. More...
 
void addRequiredData (ModelData oData)
 Adds a piece of required data to the list. More...
 
boolean [] getWhichSpeciesUsed (TreePopulation oPop)
 Returns which species to which this behavior is applied. More...
 
boolean setVectorValueByXMLTag (String sXMLTag, String sXMLParentTag, ArrayList< String > p_oData, String[] p_sChildXMLTags, boolean[] p_bAppliesTo, Attributes oParentAttributes, Attributes[] p_oAttributes) throws ModelException
 Sets a data vector's value. More...
 
boolean setSingleValueByXMLTag (String sXMLTag, String sXMLParentTag, Attributes oAttributes, Object oData) throws ModelException
 Sets a data object's value. More...
 
ModelData findObjectByXMLTag (String sXMLTag)
 Finds an object based on its XML tag. More...
 
void copySpecies (int iSpeciesCopyFrom, int iSpeciesCopyTo) throws ModelException
 Copies one species to another. More...
 
void writeXML (BufferedWriter jOut, TreePopulation oPop) throws ModelException
 Writes the XML data to a parameter file for the behaviors owned by this object. More...
 
void writeSpeciesSpecificValue (BufferedWriter jOut, ModelVector p_oData, TreePopulation oPop) throws java.io.IOException, ModelException
 Writes a set of species-specific float values to a parameter file. More...
 
void writeSpeciesSpecificValue (BufferedWriter jOut, ModelVector p_oData, TreePopulation oPop, boolean[] p_bFlags) throws java.io.IOException, ModelException
 Writes a set of species-specific values to a parameter file for a certain subset of species. More...
 
void readXMLParentTag (String sXMLTag, Attributes oAttributes) throws ModelException
 Accepts an XML parent tag (empty, no data) from the parser. More...
 
void changeOfSpeciesName (String sOldSpecies, String sNewSpecies)
 Performs any necessary tasks associated with changing the name of a species. More...
 
void changeOfSpecies (int iOldNumSpecies, int[] p_iIndexer, String[] p_sNewSpecies) throws ModelException
 Triggered when there is a change in the species list. More...
 
boolean getMustHaveTrees ()
 Gets whether this behavior must have trees. More...
 
ModelData findObjectByDescriptor (String sDescriptor)
 Finds an object based on its descriptor. More...
 
void writeBehaviorNode (BufferedWriter out, TreePopulation oPop) throws ModelException
 Writes behavior tags to the parameter file. More...
 
ArrayList< BehaviorParameterDisplayformatDataForDisplay (TreePopulation oPop)
 Formats data for display in a set of JTables. More...
 
String getAppliedToForDisplay (TreePopulation oPop)
 Get which species/types this behavior applies to, in a display-friendly format truncated to 250 chars. More...
 
void readDataFromDisplay (ArrayList< BehaviorParameterDisplay > oData, TreePopulation oPop) throws ModelException
 Reads in data from the parameter display window. More...
 
boolean canBeDuplicated ()
 Whether or not this behavior can be duplicated in the run. More...
 
void endOfParameterFileRead ()
 Called at the end of the parameter file read process. More...
 
void changeOfPlotResolution (float fOldX, float fOldY, float fNewX, float fNewY) throws ModelException
 Performs any tasks associated with a change of plot resolution. More...
 
setupType getSetupType ()
 
void writeParametersToTextFile (FileWriter jOut, TreePopulation oPop) throws IOException
 Writes the parameters for the behavior to file, using the same system as the basic parameter display and entry system. More...
 

Protected Attributes

ModelFloat m_fFuncRespPredInitDensity
 Functional response predation - predator initial density in number per square meter. More...
 
ModelFloat m_fFuncRespMaxInstDeclineRate1
 Functional response predation - max instantaneous rate at which predator abundance declines in the absense of food, in number of predators per week - season 1. More...
 
ModelFloat m_fFuncRespMaxInstDeclineRate2
 Functional response predation - max instantaneous rate at which predator abundance declines in the absense of food, in number of predators per week - season 2. More...
 
ModelFloat m_fFuncRespDemogEfficiency1
 Functional response predation - predator population's demographic efficiency - season 1. More...
 
ModelFloat m_fFuncRespDemogEfficiency2
 Functional response predation - predator population's demographic efficiency - season 2. More...
 
ModelFloat m_fFunRespDensDepCoeff1
 Functional response predation - density-dependent coefficient - season 1. More...
 
ModelFloat m_fFunRespDensDepCoeff2
 Functional response predation - density-dependent coefficient - season 2. More...
 
ModelVector mp_fFuncRespMaxIntake
 Functional response predation - maximum intake rate - number of seeds per predator per day. More...
 
ModelVector mp_fFuncRespForagingEff
 Functional response predation - foraging efficiency. More...
 
ModelFloat m_fFuncRespPropGerm
 Functional response predation - proportion of seeds, between 0 and 1, germinating each week in the germination period. More...
 
ModelInt m_iFuncRespNumWeeksSeedFall
 Functional response predation - number of weeks for which seedfall occurs. More...
 
ModelInt m_iFuncRespNumWeeksToModel
 Functional response predation - number of weeks to run model - must be less than or equal to 52. More...
 
ModelInt m_iFuncRespWeekGermStarts
 Functional response predation - week number in which germination begins. More...
 
ModelInt m_iFuncRespWeekSeason2Starts
 Functional response predation - week number in which season 2 begins. More...
 
ModelString m_sFuncRespOutputFilename
 Functional response predation - output filename. More...
 
ModelEnum m_iPreservePredatorDensities
 Functional response predation - whether or not to preserve predator densities between model timesteps (true) or re-initialize with predator initial density (false) More...
 
- Protected Attributes inherited from sortie.data.funcgroups.Behavior
GUIManager m_oManager
 GUIManager object. More...
 
BehaviorTypeBase m_oParent
 Parent manager. More...
 
ArrayList< ModelDatamp_oAllData = new ArrayList<ModelData>()
 All data for this object. More...
 
ArrayList< SpeciesTypeCombomp_oTreesAppliesTo = new ArrayList<SpeciesTypeCombo>(0)
 A set of SpeciesTypeCombo objects to which this behavior is applied - or none if it is not applied to trees. More...
 
ArrayList< Integer > mp_iGridsAppliesTo = new ArrayList<Integer>(0)
 A set of hashcodes of the Grids to which this behavior is applied - or none if it is not applied to grids. More...
 
ArrayList< DataMembermp_oNewTreeDataMembers = new ArrayList<DataMember>(0)
 The new tree data members that this behavior adds, above and beyond the basic tree population data members. More...
 
boolean m_bCanBeDuplicated = true
 Whether or not this behavior can have multiple copies in a run or not. More...
 
String m_sDescriptor = ""
 This is what will be displayed as the name of a given behavior in the GUI. More...
 
String m_sParFileTag = ""
 String which is used to identify this behavior in the parameter file. More...
 
String m_sXMLRootString = ""
 XML tag to surround this behavior's data. More...
 
String m_sHelpFileString = ""
 Help file topic identifier string. More...
 
boolean [] mp_bCanApplyToTreeType
 For each tree type, whether or not this behavior can be applied to it. More...
 
double m_fVersion = 1.0
 Version of this behavior. More...
 
double m_fMinVersion = 1.0
 Minimum version of this behavior. More...
 
int m_iListPosition = -1
 This behavior's position in the behavior list. More...
 
setupType m_iBehaviorSetupType
 

Additional Inherited Members

- Static Public Member Functions inherited from sortie.data.funcgroups.Behavior
static void setVectorValues (ModelVector oData, Float[] p_fValuesToSet, boolean[] p_bAppliesTo)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, Float[] p_fValuesToSet)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, Double[] p_fValuesToSet, boolean[] p_bAppliesTo)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, Double[] p_fValuesToSet)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, Integer[] p_iValuesToSet, boolean[] p_bAppliesTo)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, String[] p_sValuesToSet)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, String[] p_sValuesToSet, boolean[] p_bAppliesTo)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector oData, Integer[] p_iValuesToSet)
 Sets the values for vector variables. More...
 
static void setVectorValues (ModelVector p_oData, ArrayList< String > p_oValuesToSet, boolean[] p_bAppliesTo) throws ModelException
 Sets the values for vector variables. More...
 
static void writeDataToFile (BufferedWriter ojOut, ModelData oData) throws java.io. IOException
 Writes a piece of data to an XML file. More...
 
static Object [] formatBlankHeaderRow (Object[][] p_oTable)
 Creates a blank header row for a table. More...
 
static Object [][] formatDataAsComboBox (Object[][] p_oExisting, ModelEnum oToFormat)
 Adds a value with combo box formatting to an Object array for display in a JTable. More...
 
static String formatComboBoxString (ModelEnum oToFormat)
 Formats a combo box string from a ModelEnum. More...
 
static void addDataObjectToDisplayArrays (ModelData p_oDataObject, ArrayList< ModelData > p_oSingles, ArrayList< ArrayList< SpeciesSpecific >> p_oSpeciesSpecific, boolean[] p_bAppliesTo)
 Adds a data object to the arrays which will eventually display run parameters in a set of tables. More...
 
static Object [][] addDataToArray (Object[][] p_oExistingArray, Object[] p_oAddArray)
 Adds an Object array to an existing Object array. More...
 
static Object [][] formatDataForTable (Object[][] p_oExisting, ModelFloat oToFormat)
 Formats and adds a value into an Object array suitable for placing in a JTable. More...
 
static Object [][] formatDataForTable (Object[][] p_oExisting, ModelInt oToFormat)
 Formats and adds a value into an Object array suitable for placing in a JTable. More...
 
static Object [][] formatDataForTable (Object[][] p_oExisting, ModelString oToFormat)
 Formats and adds a value into an Object array suitable for placing in a JTable. More...
 
static Object [][] formatDataForTable (Object[][] p_oExisting, ModelVector oToFormat)
 Formats a vector of values into an object array and adds it to another Object array suitable for placing in a JTable. More...
 
static Object [][] formatDataForTable (Object[][] p_oExisting, ModelVector oToFormat, boolean[] p_bWhichSpecies)
 Formats a vector of values into a plain vector suitable for placing in a JTable and adds it to a vector of vectors at the end. More...
 
static Object [] formatSpeciesHeaderRow (boolean[] p_bUsed, TreePopulation oPop)
 Creates an object array of strings consisting of species names, suitable for including in the parameter entry table. More...
 
static void ensureSize (ArrayList<?> list, int size)
 Ensure an ArrayList is at least a specific size. More...
 
- Public Attributes inherited from sortie.data.funcgroups.Behavior
boolean m_bMustHaveTrees = true
 If true, and a tree has no species/type combos, it automatically becomes disabled. More...
 
- Protected Member Functions inherited from sortie.data.funcgroups.Behavior
void setSingleValue (ModelData oDataMember, Object oData) throws ModelException
 Sets the value of a single data member. More...
 
BehaviorParameterDisplay formatTable (ArrayList< ModelData > p_oSingles, ArrayList< ArrayList< SpeciesSpecific >> p_oSpeciesSpecific, TreePopulation oPop)
 Turns vector groups of data objects into a set of tables for display. More...
 
- Static Protected Member Functions inherited from sortie.data.funcgroups.Behavior
static boolean boolArraysEqual (boolean[] p_bArrayOne, boolean[] p_bArrayTwo)
 Tests two boolean arrays for equality. More...
 

Detailed Description

Corresponds to the clFuncResponseSeedPredation class.

Author
lora

Constructor & Destructor Documentation

◆ FuncResponseSeedPredation()

sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.FuncResponseSeedPredation ( GUIManager  oManager,
BehaviorTypeBase  oParent,
String  sDescriptor,
String  sParFileTag,
String  sXMLRootString 
) throws ModelException

Constructor.

Parameters
oManagerGUIManager object
oParentParent managing object.
sDescriptorThe name of the behavior for the user.
sParFileTagString which is used to identify this behavior in the parameter file.
sXMLRootStringXML tag to surround this behavior's data.
Exceptions
ModelException

Member Function Documentation

◆ validateData()

void sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.validateData ( TreePopulation  oPop) throws ModelException

Validates the dataset if seed predation is enabled.

Parameters
oPopTreePopulation object.
Exceptions
ModelExceptionif:
  • Number of weeks of seedfall is less than or equal to zero
  • Initial predator density is less than or equal to zero
  • Number of weeks to run the model is less than 0 or greater than 52
  • Week to start germination is less than 0 or greater than 52
  • Proportion germinating is not a proportion
  • The seed predation behavior is present without a disperse behavior also enabled

Member Data Documentation

◆ m_fFuncRespDemogEfficiency1

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFuncRespDemogEfficiency1
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Demographic Efficiency, Season 1",
"pr_funcRespDemographicEfficiency1")

Functional response predation - predator population's demographic efficiency - season 1.

◆ m_fFuncRespDemogEfficiency2

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFuncRespDemogEfficiency2
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Demographic Efficiency, Season 2",
"pr_funcRespDemographicEfficiency2")

Functional response predation - predator population's demographic efficiency - season 2.

◆ m_fFuncRespMaxInstDeclineRate1

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFuncRespMaxInstDeclineRate1
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Max Decline Rate, Season 1, predators/week",
"pr_funcRespMaxInstDeclineRate1")

Functional response predation - max instantaneous rate at which predator abundance declines in the absense of food, in number of predators per week - season 1.

◆ m_fFuncRespMaxInstDeclineRate2

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFuncRespMaxInstDeclineRate2
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Max Decline Rate, Season 2, predators/week",
"pr_funcRespMaxInstDeclineRate2")

Functional response predation - max instantaneous rate at which predator abundance declines in the absense of food, in number of predators per week - season 2.

◆ m_fFuncRespPredInitDensity

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFuncRespPredInitDensity
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Predator Initial Density - num/sq m", "pr_funcRespPredatorInitialDensity")

Functional response predation - predator initial density in number per square meter.

◆ m_fFuncRespPropGerm

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFuncRespPropGerm
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Proportion of Seeds Germinating Each Week",
"pr_funcRespProportionGerminating")

Functional response predation - proportion of seeds, between 0 and 1, germinating each week in the germination period.

◆ m_fFunRespDensDepCoeff1

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFunRespDensDepCoeff1
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Density Dependent Coeff, Season 1",
"pr_funcRespDensityDependentCoefficient1")

Functional response predation - density-dependent coefficient - season 1.

◆ m_fFunRespDensDepCoeff2

ModelFloat sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_fFunRespDensDepCoeff2
protected
Initial value:
= new ModelFloat(0,
"Func Resp - Density Dependent Coeff, Season 2",
"pr_funcRespDensityDependentCoefficient2")

Functional response predation - density-dependent coefficient - season 2.

◆ m_iFuncRespNumWeeksSeedFall

ModelInt sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_iFuncRespNumWeeksSeedFall
protected
Initial value:
= new ModelInt(0,
"Func Resp - Number of Weeks in Which Seedfall Occurs",
"pr_funcRespNumWeeksSeedFall")

Functional response predation - number of weeks for which seedfall occurs.

◆ m_iFuncRespNumWeeksToModel

ModelInt sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_iFuncRespNumWeeksToModel
protected
Initial value:
= new ModelInt(0,
"Func Resp - Weeks to Run Seed Predation Model (1 - 52)",
"pr_funcRespNumWeeksToModel")

Functional response predation - number of weeks to run model - must be less than or equal to 52.

◆ m_iFuncRespWeekGermStarts

ModelInt sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_iFuncRespWeekGermStarts
protected
Initial value:
= new ModelInt(0,
"Func Resp - Week Germination Begins",
"pr_funcRespWeekGerminationStarts")

Functional response predation - week number in which germination begins.

◆ m_iFuncRespWeekSeason2Starts

ModelInt sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_iFuncRespWeekSeason2Starts
protected
Initial value:
= new ModelInt(0,
"Func Resp - Week Season 2 Begins",
"pr_funcRespWeekSeason2Starts")

Functional response predation - week number in which season 2 begins.

◆ m_iPreservePredatorDensities

ModelEnum sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_iPreservePredatorDensities
protected
Initial value:
= new ModelEnum(
new int[] {0, 1}, new String[] {"false", "true"},
"Func Resp - Keep Predator Densities Between Timesteps",
"pr_funcRespPreservePredatorDensities")

Functional response predation - whether or not to preserve predator densities between model timesteps (true) or re-initialize with predator initial density (false)

◆ m_sFuncRespOutputFilename

ModelString sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.m_sFuncRespOutputFilename
protected
Initial value:
= new ModelString("",
"Func Resp - Seed Predation Output Filename, If Desired",
"pr_funcRespOutputFilename")

Functional response predation - output filename.

◆ mp_fFuncRespForagingEff

ModelVector sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.mp_fFuncRespForagingEff
protected
Initial value:
= new ModelVector(
"Func Resp - Foraging Efficiency", "pr_funcRespForagingEfficiency", "pr_frfeVal",
0, ModelVector.FLOAT)

Functional response predation - foraging efficiency.

◆ mp_fFuncRespMaxIntake

ModelVector sortie.data.funcgroups.seedpredation.FuncResponseSeedPredation.mp_fFuncRespMaxIntake
protected
Initial value:
= new ModelVector(
"Func Resp - Max Intake Rate - seeds per predator per day",
"pr_funcRespMaxIntakeRate", "pr_frmirVal", 0, ModelVector.FLOAT)

Functional response predation - maximum intake rate - number of seeds per predator per day.


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