openthread-br  0.3.0-72c0388
Public Member Functions | Static Public Member Functions | List of all members
otbr::MainloopManager Class Reference

#include <src/common/mainloop_manager.hpp>

Inheritance diagram for otbr::MainloopManager:
NonCopyable

Public Member Functions

 MainloopManager ()=default
 
void AddMainloopProcessor (MainloopProcessor *aMainloopProcessor)
 
void RemoveMainloopProcessor (MainloopProcessor *aMainloopProcessor)
 
void Update (MainloopContext &aMainloop)
 
void Process (const MainloopContext &aMainloop)
 

Static Public Member Functions

static MainloopManagerGetInstance (void)
 

Detailed Description

This class implements the mainloop manager.

Constructor & Destructor Documentation

◆ MainloopManager()

otbr::MainloopManager::MainloopManager ( )
default

The constructor to initialize the mainloop manager.

Member Function Documentation

◆ AddMainloopProcessor()

void otbr::MainloopManager::AddMainloopProcessor ( MainloopProcessor aMainloopProcessor)

This method adds a mainloop processors to the mainloop managger.

Parameters
[in]aMainloopProcessorA pointer to the mainloop processor.

◆ GetInstance()

static MainloopManager& otbr::MainloopManager::GetInstance ( void  )
inlinestatic

This method returns the singleton instance of the mainloop manager.

◆ Process()

void otbr::MainloopManager::Process ( const MainloopContext aMainloop)

This method processes mainloop events of all mainloop processors.

Parameters
[in]aMainloopA reference to the mainloop context.

◆ RemoveMainloopProcessor()

void otbr::MainloopManager::RemoveMainloopProcessor ( MainloopProcessor aMainloopProcessor)

This method removes a mainloop processors from the mainloop managger.

Parameters
[in]aMainloopProcessorA pointer to the mainloop processor.

◆ Update()

void otbr::MainloopManager::Update ( MainloopContext aMainloop)

This method updates the mainloop context of all mainloop processors.

Parameters
[in,out]aMainloopA reference to the mainloop to be updated.

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