Documentation of UrbanFireXDT
Documentation of UrbanFireXDT
Loading...
Searching...
No Matches
Static Public Member Functions | List of all members
StatusOutput Class Reference

A thread-safe logging and status output system using ncurses. More...

#include <status_output.hpp>

Static Public Member Functions

static void add_status_output (const std::string &message)
 Adds a message to the simulation output log.
 
static void add_error_message (const std::string &error)
 Adds an error message to the error log.
 
static void initialize_ncurses ()
 Initializes the ncurses interface.
 
static void shutdown_ncurses ()
 Shuts down the ncurses interface.
 
static void start_status_updater_thread ()
 Starts the background thread that periodically updates the status display.
 
static void stop_status_updater_thread ()
 Stops the background status updater thread.
 

Detailed Description

A thread-safe logging and status output system using ncurses.

This class provides a singleton-style interface for handling real-time status output in a terminal window divided into three panes:

It also logs messages to separate log files.

Member Function Documentation

◆ add_error_message()

void StatusOutput::add_error_message ( const std::string &  error)
static

Adds an error message to the error log.

Parameters
errorThe error message to be logged.

◆ add_status_output()

void StatusOutput::add_status_output ( const std::string &  message)
static

Adds a message to the simulation output log.

Parameters
messageThe message to be logged.

◆ initialize_ncurses()

void StatusOutput::initialize_ncurses ( )
static

Initializes the ncurses interface.

This must be called at the start of main() before any output is displayed.

◆ shutdown_ncurses()

void StatusOutput::shutdown_ncurses ( )
static

Shuts down the ncurses interface.

This should be called before the program terminates to restore the terminal state.

◆ start_status_updater_thread()

void StatusOutput::start_status_updater_thread ( )
static

Starts the background thread that periodically updates the status display.

This should be called when the main simulation run starts.

◆ stop_status_updater_thread()

void StatusOutput::stop_status_updater_thread ( )
static

Stops the background status updater thread.

This should be called when the simulation ends to properly clean up resources.


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