ADTF
Loading...
Searching...
No Matches
A_UTILS_NS::log::cCurrentThreadDefaultLogChannel Class Referencefinal

#include <log.h>

Public Member Functions

 cCurrentThreadDefaultLogChannel (ILogChannel *pChannel) noexcept
 
 cCurrentThreadDefaultLogChannel (const cCurrentThreadDefaultLogChannel &)=delete
 
 cCurrentThreadDefaultLogChannel (cCurrentThreadDefaultLogChannel &&)=delete
 
 ~cCurrentThreadDefaultLogChannel () noexcept
 

Detailed Description

Use an object of this on the stack !only! to push a log channel onto the current log channel stack. The destructor will remove it from the stack again.

Never allocate this on the heap or as a member of another class!

Constructor & Destructor Documentation

◆ cCurrentThreadDefaultLogChannel()

A_UTILS_NS::log::cCurrentThreadDefaultLogChannel::cCurrentThreadDefaultLogChannel ( ILogChannel * pChannel)
noexcept

Pushes the given channel onto the log channel stack. So any LOG_* calls will use this channel while this object exists and no other channel was pushed onto the stack.

Parameters
[in]pChannelThe channel which should be pushed.

◆ ~cCurrentThreadDefaultLogChannel()

A_UTILS_NS::log::cCurrentThreadDefaultLogChannel::~cCurrentThreadDefaultLogChannel ( )
noexcept

This has to be called in the same thread from which the object was created. Removes the channel from the top of the log channel stack.


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