Health-GPS  1.2.2.0
Global Health Policy Simulation model (Health-GPS)
hgps::SyncDataMessage< PayloadType > Class Template Referencefinal

Implements a synchronisation message with payload. More...

#include <sync_message.h>

Inheritance diagram for hgps::SyncDataMessage< PayloadType >:
[legend]
Collaboration diagram for hgps::SyncDataMessage< PayloadType >:
[legend]

Public Member Functions

 SyncDataMessage (const int run, const int time, PayloadType &&data)
 Initialises a new instance of the SyncMessage class. More...
 
const PayloadType & data () const noexcept
 Gets the message payload data. More...
 
- Public Member Functions inherited from hgps::SyncMessage
 SyncMessage (const int run, const int time)
 Initialises a new instance of the SyncMessage class. More...
 
 SyncMessage (const SyncMessage &)=delete
 
SyncMessageoperator= (const SyncMessage &)=delete
 
virtual ~SyncMessage ()=default
 Destroys a SyncMessage instance. More...
 
int run () const noexcept
 Gets the Simulation run number. More...
 
int time () const noexcept
 Gets the Simulation time. More...
 

Additional Inherited Members

- Protected Member Functions inherited from hgps::SyncMessage
 SyncMessage (SyncMessage &&other)=default
 Moves the target of other to the target of *this. More...
 
SyncMessageoperator= (SyncMessage &&other)=default
 Moves the target of other to *this. More...
 

Detailed Description

template<typename PayloadType>
class hgps::SyncDataMessage< PayloadType >

Implements a synchronisation message with payload.

Template Parameters
PayloadTypeThe payload type

Constructor & Destructor Documentation

◆ SyncDataMessage()

template<typename PayloadType >
hgps::SyncDataMessage< PayloadType >::SyncDataMessage ( const int  run,
const int  time,
PayloadType &&  data 
)
inlineexplicit

Initialises a new instance of the SyncMessage class.

Parameters
runSimulation run number
timeSimulation time
dataThe payload data instance

Member Function Documentation

◆ data()

template<typename PayloadType >
const PayloadType& hgps::SyncDataMessage< PayloadType >::data ( ) const
inlinenoexcept

Gets the message payload data.

Returns
The payload data

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