Health-GPS 3.0.0.0
Global Health Policy Simulation model (Health-GPS)
Loading...
Searching...
No Matches
hgps::BaselineScenario Class Referencefinal

Defines the baseline scenario data type. More...

#include <baseline_scenario.h>

Inheritance diagram for hgps::BaselineScenario:
[legend]
Collaboration diagram for hgps::BaselineScenario:
[legend]

Public Member Functions

 BaselineScenario ()=delete
 
 BaselineScenario (SyncChannel &data_sync)
 Initialises a new instance of the BaselineScenario class.
 
ScenarioType type () const noexcept override
 Gets the scenario type identifier.
 
const std::string & name () const noexcept override
 Gets the scenario type name.
 
SyncChannel & channel () override
 Gets the Scenario communication channel.
 
void clear () noexcept override
 Clear the scenario log book data.
 
double apply (Random &generator, Person &entity, int time, const core::Identifier &risk_factor_key, double value) override
 Applies this Scenario to the Person instance.
 
- Public Member Functions inherited from hgps::Scenario
virtual ~Scenario ()=default
 Destroys a Scenario instance.
 

Detailed Description

Defines the baseline scenario data type.

The baseline scenario is a special case, which identify the type as ScenarioType::baseline and when applied to a Person makes no changes to any risk factor value. This implementation is final.

Constructor & Destructor Documentation

◆ BaselineScenario() [1/2]

hgps::BaselineScenario::BaselineScenario ( )
delete

◆ BaselineScenario() [2/2]

hgps::BaselineScenario::BaselineScenario ( SyncChannel &  data_sync)

Initialises a new instance of the BaselineScenario class.

Parameters
data_syncThe data synchronisation channel instance to use.

Member Function Documentation

◆ apply()

double hgps::BaselineScenario::apply ( Random &  generator,
Person &  entity,
int  time,
const core::Identifier &  risk_factor_key,
double  value 
)
overridevirtual

Applies this Scenario to the Person instance.

Parameters
generatorRandom number generator instance
entityPerson instance to apply
timeCurrent simulation time
risk_factor_keyTarget risk factor identifier
valueCurrent risk factor value
Returns
The risk factor new value

Implements hgps::Scenario.

◆ channel()

SyncChannel & hgps::BaselineScenario::channel ( )
overridevirtual

Gets the Scenario communication channel.

Returns
The communication channel

Implements hgps::Scenario.

◆ clear()

void hgps::BaselineScenario::clear ( )
overridevirtualnoexcept

Clear the scenario log book data.

Implements hgps::Scenario.

◆ name()

const std::string & hgps::BaselineScenario::name ( ) const
overridevirtualnoexcept

Gets the scenario type name.

Returns
Scenario type name

Implements hgps::Scenario.

◆ type()

ScenarioType hgps::BaselineScenario::type ( ) const
overridevirtualnoexcept

Gets the scenario type identifier.

Returns
The scenario type

Implements hgps::Scenario.


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