ALMaSS  1.2 (after EcoStack, March 2024)
The Animal, Landscape and Man Simulation System
CfgArray_Double Class Reference

#include <Configurator.h>

Inheritance diagram for CfgArray_Double:
CfgBase CfgFunction

Public Member Functions

 CfgArray_Double (const std::string &a_name, CfgSecureLevel a_level, int a_numofvals, const std::vector< double > &a_defval)
 
 CfgArray_Double (const std::string &a_name, CfgSecureLevel a_level, int a_numofvals, const std::vector< double > &a_defval, bool a_definconf)
 
 CfgArray_Double (const std::string &a_key, CfgSecureLevel a_level, int a_numvals)
 
std::vector< double > value () const
 
void set (std::vector< double > a_newval)
 
virtual CfgType gettype ()
 
int get_array_size ()
 
double value (unsigned a_index)
 
- Public Member Functions inherited from CfgBase
 CfgBase (const std::string &a_key, CfgSecureLevel a_level)
 
 CfgBase (const std::string &a_key, CfgSecureLevel a_level, bool a_definedinconfig)
 
virtual ~CfgBase ()
 
std::string getkey ()
 
CfgSecureLevel getlevel (void)
 
void set_definedinconfig (bool flag)
 
bool get_definedinconfig () const
 
bool get_rangetest () const
 

Protected Attributes

int array_size {0}
 
std::vector< double > m_doublearray {}
 
- Protected Attributes inherited from CfgBase
std::string m_key
 
CfgSecureLevel m_level
 
bool m_rangetest
 
bool m_definedinconfig {false}
 

Constructor & Destructor Documentation

◆ CfgArray_Double() [1/3]

CfgArray_Double::CfgArray_Double ( const std::string &  a_name,
CfgSecureLevel  a_level,
int  a_numofvals,
const std::vector< double > &  a_defval 
)
261  :CfgBase( a_key, a_level )
262 {
263  array_size = a_numvals;
264  m_doublearray = a_defval;
265  g_cfg->Register( this, a_key );
266 }

References array_size, g_cfg, and m_doublearray.

◆ CfgArray_Double() [2/3]

CfgArray_Double::CfgArray_Double ( const std::string &  a_name,
CfgSecureLevel  a_level,
int  a_numofvals,
const std::vector< double > &  a_defval,
bool  a_definconf 
)
278  :CfgBase{ a_key, a_level, a_definconf }
279 {
280  array_size = a_numvals;
281  m_doublearray = a_defval;
282 }

◆ CfgArray_Double() [3/3]

CfgArray_Double::CfgArray_Double ( const std::string &  a_key,
CfgSecureLevel  a_level,
int  a_numvals 
)
269  :CfgBase( a_key, a_level )
270 {
271  array_size = a_numvals;
272 
273  g_cfg->Register( this, a_key );
274 }

References array_size, and g_cfg.

Member Function Documentation

◆ get_array_size()

int CfgArray_Double::get_array_size ( )
inline

◆ gettype()

virtual CfgType CfgArray_Double::gettype ( void  )
inlinevirtual

Reimplemented from CfgBase.

Reimplemented in CfgFunction.

221 { return CFG_ARRAY_DOUBLE; }

References CFG_ARRAY_DOUBLE.

◆ set()

void CfgArray_Double::set ( std::vector< double >  a_newval)
inline
220 { m_doublearray = std::move(a_newval); }

References m_doublearray.

◆ value() [1/2]

std::vector<double> CfgArray_Double::value ( ) const
inline
219 { return m_doublearray; }

References m_doublearray.

Referenced by Aphid_Population_Manager::Aphid_Population_Manager(), Beetle_Population_Manager::Beetle_Population_Manager(), Bembidion_Population_Manager::Bembidion_Population_Manager(), Aphid::calBioticMortalityRateShared(), Ladybird_Pupae::calcDailyMortChance(), Aphid::calCellRelatedMortalityWeight(), LE::CalculateFlowerResourceForCrop(), Aphid::calPopuDensity(), Farm::CattleIsOut(), Farm::CattleOut(), Ladybird_Population_Manager::DayDegreeCalculations(), Beetle_Population_Manager::DayDegreeCalculations(), OrchardCrop::Do(), CloverGrassGrazed2::Do(), DK_CerealLegume::Do(), DK_CerealLegume_Whole::Do(), DK_SpringBarley_Green::Do(), FodderGrass::Do(), DK_Legume_Peas::Do(), BEOrchardCrop::Do(), DK_SpringBarleySilage::Do(), CloverGrassGrazed1::Do(), DK_FodderBeet::Do(), NLOrchardCrop::Do(), DK_SpringOats::Do(), DK_SugarBeet::Do(), DK_SpringOats_CC::Do(), DK_Legume_Beans::Do(), UKBeans::Do(), DK_SpringWheat::Do(), DK_Legume_Whole::Do(), FI_Potato_North::Do(), FI_StarchPotato_North::Do(), SpringBarleyCloverGrass::Do(), FI_PotatoIndustry_North::Do(), FI_Potato_South::Do(), FI_PotatoIndustry_South::Do(), FI_StarchPotato_South::Do(), DK_SpringBarleyCloverGrass::Do(), UKSpringBarley::Do(), UKWinterBarley::Do(), DK_WinterFodderGrass::Do(), DK_SpringBarley::Do(), DK_SpringBarley_CC::Do(), DK_SpringFodderGrass::Do(), DK_WinterCloverGrassGrazedSown::Do(), BEWinterBarley::Do(), BEWinterBarleyCC::Do(), NLCabbageSpring::Do(), NLSpringBarleySpring::Do(), DK_VegSeeds::Do(), BEWinterWheat::Do(), BEWinterWheatCC::Do(), DK_WinterRye::Do(), DK_WinterRye_CC::Do(), DK_Carrots_Spring::Do(), NLCabbage::Do(), SpringBarleySilage::Do(), SpringBarleySpr::Do(), DK_Carrots::Do(), UKWinterWheat::Do(), PLCarrots::Do(), TestCrop::Do(), DK_Cabbages::Do(), SpringBarleyPTreatment::Do(), NLSpringBarley::Do(), PLSpringBarleySpr::Do(), NLWinterWheat::Do(), SpringBarley::Do(), DK_WinterWheat::Do(), DK_WinterWheat_CC::Do(), PLFodderLucerne1::Do(), DK_Potato::Do(), UKPotatoes::Do(), FI_Caraway2::Do(), SpringRape::Do(), DK_MixedVeg::Do(), PLBeetSpr::Do(), PLBeans::Do(), DK_WinterRape::Do(), DK_PotatoSeed::Do(), WinterRape::Do(), BEPotatoesSpring::Do(), DE_BushFruitPerm::Do(), DE_Maize::Do(), DE_MaizeSilage::Do(), DK_PotatoIndustry::Do(), FR_SpringBarley::Do(), FR_SpringOats::Do(), NLPotatoesSpring::Do(), PLWinterRye::Do(), DE_SpringBarley::Do(), FI_TurnipRape::Do(), BEPotatoes::Do(), FR_Maize::Do(), FR_Maize_Silage::Do(), DE_AsparagusEstablishedPlantation::Do(), PLMaize::Do(), PLMaizeSilage::Do(), PLSpringBarley::Do(), NLPotatoes::Do(), NLTulips::Do(), FI_SpringRape::Do(), DE_Peas::Do(), FI_SpringBarley_Malt::Do(), PLWinterTriticale::Do(), FR_Sunflower::Do(), DE_Legumes::Do(), DE_WinterRye::Do(), FI_SprSpringBarley_Fodder::Do(), DK_CloverGrassGrazed3::Do(), PLBeet::Do(), PLWinterBarley::Do(), PLWinterWheat::Do(), FI_SpringWheat::Do(), PLSpringWheat::Do(), PLWinterWheatLate::Do(), FI_SpringOats::Do(), DK_CloverGrassGrazed2::Do(), PLPotatoes::Do(), DK_BushFruit_Perm1::Do(), FI_SpringBarley_Fodder::Do(), DE_Oats::Do(), DE_Cabbage::Do(), DE_WinterBarley::Do(), FR_SpringWheat::Do(), DE_SpringRye::Do(), PLWinterRape::Do(), PTVineyards::Do(), DK_BushFruit_Perm2::Do(), FR_WinterBarley::Do(), FI_WinterWheat::Do(), DE_Triticale::Do(), FI_WinterRye::Do(), FR_WinterWheat::Do(), DE_WinterWheatLate::Do(), DE_WinterWheat::Do(), FR_Potatoes::Do(), FR_WinterRape::Do(), DE_WinterRape::Do(), DE_Orchard::Do(), WinterWheat::Do(), DE_SugarBeet::Do(), DK_OrchCherry::Do(), DE_Potatoes::Do(), DK_OrchPear::Do(), DK_OrchardCrop_Perm::Do(), DK_OrchOther::Do(), DK_OrchApple::Do(), DE_PotatoesIndustry::Do(), PesticideStore::doDecay(), FieldBoundary::DoDevelopment(), Aphid::doMovement(), PesticideToxicity::doToxicity(), Configurator::DumpSymbols(), Ladybird_Adult::GetExtremeTempMin(), Osmia_Population_Manager::Init(), Aphid_Population_Manager::initialisePopulation(), Ladybird_Population_Manager::Ladybird_Population_Manager(), Aphid::OnFarmEvent(), Osmia_Population_Manager::Osmia_Population_Manager(), OsmiaParasitoid_Population_Manager::OsmiaParasitoid_Population_Manager(), PoecilusCupreus_Population_Manager::PoecilusCupreus_Population_Manager(), Pesticide::Tick(), Ladybird_Adult::TryToReproduce(), PollenNectarDevelopmentCurveSet::UpdateFlowerResource(), and VegElement::VegElement().

◆ value() [2/2]

double CfgArray_Double::value ( unsigned  a_index)
inline
223 { return m_doublearray[a_index]; }

References m_doublearray.

Member Data Documentation

◆ array_size

int CfgArray_Double::array_size {0}
protected

Referenced by CfgArray_Double(), and get_array_size().

◆ m_doublearray

std::vector<double> CfgArray_Double::m_doublearray {}
protected

Referenced by CfgArray_Double(), set(), and value().


The documentation for this class was generated from the following files:
CFG_ARRAY_DOUBLE
Definition: Configurator.h:65
CfgArray_Double::m_doublearray
std::vector< double > m_doublearray
Definition: Configurator.h:212
g_cfg
std::shared_ptr< Configurator > g_cfg
Definition: Configurator.cpp:56
CfgBase::CfgBase
CfgBase(const std::string &a_key, CfgSecureLevel a_level)
Definition: Configurator.cpp:84
CfgArray_Double::array_size
int array_size
Definition: Configurator.h:211
CfgBase
Base class for a configurator entry.
Definition: Configurator.h:79