Icarus
Vehicle Simulation as a Transformable Computational Graph, built on Vulcan and Janus
Loading...
Searching...
No Matches
icarus::LogContextManager Class Reference

Thread-local log context manager. More...

#include <LogService.hpp>

Classes

class  ScopedContext
 RAII guard for automatic context management. More...

Static Public Member Functions

static void SetContext (const LogContext &ctx)
 Set context for current thread (called by Simulator before Step).
static void ClearContext ()
 Clear context (called by Simulator after Step).
static const LogContextGetContext ()
 Get current context (called internally by LogBuffer::Log).

Detailed Description

Thread-local log context manager.

The Simulator sets this before calling component methods. Components can query GetCurrentContext() implicitly.

Member Function Documentation

◆ ClearContext()

void icarus::LogContextManager::ClearContext ( )
inlinestatic

Clear context (called by Simulator after Step).

◆ GetContext()

const LogContext & icarus::LogContextManager::GetContext ( )
inlinestaticnodiscard

Get current context (called internally by LogBuffer::Log).

◆ SetContext()

void icarus::LogContextManager::SetContext ( const LogContext & ctx)
inlinestatic

Set context for current thread (called by Simulator before Step).


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