ALMaSS  1.2 (after EcoStack, March 2024)
The Animal, Landscape and Man Simulation System
AOR_Probe.h
Go to the documentation of this file.
1 #pragma once
2 typedef vector < int > ListOfCells;
3 
4 class AOR_Probe
5 {
6 protected:
7  ofstream m_ProbeFile;
8  ofstream m_ProbeFileHL;
12  int m_totalcells[4];
15 
19 public:
20  AOR_Probe(Population_Manager* a_owner, Landscape* a_TheLandscape, string a_filename);
21  virtual ~AOR_Probe() {
22  CloseFile();
23  }
24 
25  virtual void CloseFile() {
26  m_ProbeFile.close();
27  }
28  void WriteData();
29  void WriteDataHL();
30  virtual void DoProbe(int a_lifestage);
32  virtual void DoProbeInHaitatType(int a_lifestage, TTypesOfLandscapeElement a_tole);
33 };
34 
35 class AOR_Probe_Goose : public AOR_Probe
36 {
37 protected:
38 public:
39  AOR_Probe_Goose(Population_Manager* a_owner, Landscape* a_TheLandscape, string a_filename);
40  virtual void DoProbe(int a_lifestage);
41 };
ListOfCells
vector< int > ListOfCells
Definition: AOR_Probe.h:2
PopulationManager.h
PopulationManager.h This is the header file for the population manager and associated classes
WARN_FILE
Definition: MapErrorMsg.h:37
cfg_AOR_Habitat_Location_On
static CfgBool cfg_AOR_Habitat_Location_On("G_AOR_HABITAT_ON", CFG_CUSTOM, false)
Flag for using the habitat location probe.
TAnimal::SupplyPoint
APoint SupplyPoint() const
Returns the objects location in ALMaSS coordinates.
Definition: PopulationManager.h:222
Population_Manager::SupplyAnimalPtr
virtual TAnimal * SupplyAnimalPtr(unsigned int a_index, unsigned int a_animal)
Returns the pointer indexed by a_index and a_animal. Note NO RANGE CHECK.
Definition: PopulationManager.h:678
AOR_Probe_Goose::AOR_Probe_Goose
AOR_Probe_Goose(Population_Manager *a_owner, Landscape *a_TheLandscape, string a_filename)
Definition: AOR_Probe.cpp:130
tole_Foobar
Definition: LandscapeFarmingEnums.h:183
AOR_Probe.h
AOR_Probe::CloseFile
virtual void CloseFile()
Definition: AOR_Probe.h:25
CfgBool::value
bool value() const
Definition: Configurator.h:164
AOR_Probe::~AOR_Probe
virtual ~AOR_Probe()
Definition: AOR_Probe.h:21
TTypesOfLandscapeElement
TTypesOfLandscapeElement
Values that represent the types of landscape polygon that are represented in ALMaSS.
Definition: LandscapeFarmingEnums.h:57
Landscape
The landscape class containing all environmental and topographical data.
Definition: Landscape.h:142
AOR_Probe::DoProbe
virtual void DoProbe(int a_lifestage)
Definition: AOR_Probe.cpp:104
AOR_Probe::DoProbeInHaitatType
virtual void DoProbeInHaitatType(int a_lifestage, TTypesOfLandscapeElement a_tole)
Records the locations of all beetles and classifies them as to in a habitat type or not.
Definition: AOR_Probe.cpp:164
AOR_Probe::m_owner
Population_Manager * m_owner
Definition: AOR_Probe.h:18
APoint
A simple class defining an x,y coordinate set.
Definition: ALMaSS_Setup.h:52
CfgBool
Bool configurator entry class.
Definition: Configurator.h:155
AOR_Probe
Definition: AOR_Probe.h:4
MapErrorMsg::Warn
void Warn(MapErrorState a_level, std::string a_msg1, std::string a_msg2)
Definition: MapErrorMsg.cpp:69
AOR_Probe::m_gridcountheight
int m_gridcountheight[4]
Definition: AOR_Probe.h:10
Population_Manager
Base class for all population managers for agent based models.
Definition: PopulationManager.h:645
AOR_Probe::m_ProbeFile
ofstream m_ProbeFile
Definition: AOR_Probe.h:7
APoint::m_x
int m_x
Definition: ALMaSS_Setup.h:55
AOR_Probe::m_totalcells
int m_totalcells[4]
Definition: AOR_Probe.h:12
AOR_Probe_Goose::DoProbe
virtual void DoProbe(int a_lifestage)
Definition: AOR_Probe.cpp:135
AOR_Probe::m_gridcount
ListOfCells m_gridcount[4]
Definition: AOR_Probe.h:13
CfgInt::value
int value() const
Definition: Configurator.h:116
AOR_Probe::m_gridcountHLoc
ListOfCells m_gridcountHLoc[4]
Definition: AOR_Probe.h:14
g_msg
MapErrorMsg * g_msg
Definition: MapErrorMsg.cpp:41
Population_Manager::GetLiveArraySize
unsigned GetLiveArraySize(int a_listindex) override
Gets the number of 'live' objects for a list index in the TheArray.
Definition: PopulationManager.h:657
CfgInt
Integer configurator entry class.
Definition: Configurator.h:102
AOR_Probe::m_gridcountwidth
int m_gridcountwidth[4]
Definition: AOR_Probe.h:9
AOR_Probe::m_TheLandscape
Landscape * m_TheLandscape
Definition: AOR_Probe.h:16
CFG_CUSTOM
Definition: Configurator.h:70
AOR_Probe::m_ProbeFileHL
ofstream m_ProbeFileHL
Definition: AOR_Probe.h:8
AOR_Probe::AOR_Probe
AOR_Probe(Population_Manager *a_owner, Landscape *a_TheLandscape, string a_filename)
Definition: AOR_Probe.cpp:15
AOR_Probe_Goose
Definition: AOR_Probe.h:35
cfg_AOR_Habitat_Location_Type
static CfgInt cfg_AOR_Habitat_Location_Type("G_AOR_HABITAT_TYPE", CFG_CUSTOM, 20)
ALMaSS tole code for the habitat location probe to count in - default 20 = tole_Field.
AOR_Probe::WriteData
void WriteData()
Definition: AOR_Probe.cpp:56
APoint::m_y
int m_y
Definition: ALMaSS_Setup.h:56
AOR_Probe::WriteDataHL
void WriteDataHL()
Definition: AOR_Probe.cpp:82
AOR_Probe::m_target_tole
TTypesOfLandscapeElement m_target_tole
Definition: AOR_Probe.h:17
AOR_Probe::m_gridcountsize
int m_gridcountsize[4]
Definition: AOR_Probe.h:11