Woman, Life, Freedom


Adaptive AUTOSAR
ARA public interface header documentation
ara::phm::supervisors::GlobalSupervision Class Reference

A class to report the global supervision status based on several elementary supervisions. More...

#include <global_supervision.h>

Public Member Functions

 GlobalSupervision (std::initializer_list< ElementarySupervision * > supervisors)
 Constructor. More...
 
SupervisionStatus GetStatus () const noexcept
 Get the supervision status. More...
 
void SetCallback (std::function< void(SupervisionUpdate)> &&callback)
 Set a callback to be invoked on the global supervision status change. More...
 

Detailed Description

A class to report the global supervision status based on several elementary supervisions.

See also
ElementarySupervision

Constructor & Destructor Documentation

◆ GlobalSupervision()

ara::phm::supervisors::GlobalSupervision::GlobalSupervision ( std::initializer_list< ElementarySupervision * >  supervisors)
explicit

Constructor.

Parameters
supervisorsA list of elementary supervision pointers

Member Function Documentation

◆ GetStatus()

SupervisionStatus ara::phm::supervisors::GlobalSupervision::GetStatus ( ) const
noexcept

Get the supervision status.

Returns
Current global supervision status

◆ SetCallback()

void ara::phm::supervisors::GlobalSupervision::SetCallback ( std::function< void(SupervisionUpdate)> &&  callback)

Set a callback to be invoked on the global supervision status change.

Parameters
callbackOn supervision status changed callback