TSDuck v3.43-4509
MPEG Transport Stream Toolkit
Loading...
Searching...
No Matches

Message severity. More...

#include <tsSeverity.h>

Static Public Member Functions

static UString AddHeader (int severity, const UString &message)
 Added the prefix header for a severity to a given message.
 
static const NamesEnums ()
 An enumeration to use severity values on the command line for instance.
 
static UString Header (int severity)
 Formatted line prefix header for a severity.
 

Static Public Attributes

static constexpr int Debug = 1
 First debug level.
 
static constexpr int Error = -3
 Regular error.
 
static constexpr int Fatal = -5
 Fatal error, typically aborts the application.
 
static constexpr int Info = -1
 Information message.
 
static constexpr int Severe = -4
 Severe errror.
 
static constexpr int Verbose = 0
 Verbose information.
 
static constexpr int Warning = -2
 Warning message.
 

Detailed Description

Message severity.

Positive values are debug levels. The typical default reporting level is Info. All messages with a higher level (Verbose and all debug levels) are not reported by default.

The struct is here just to add a naming level.

Member Function Documentation

◆ Header()

static UString ts::Severity::Header ( int  severity)
static

Formatted line prefix header for a severity.

Parameters
[in]severitySeverity value.
Returns
A string to prepend to messages. Empty for Info and Verbose levels.

◆ AddHeader()

static UString ts::Severity::AddHeader ( int  severity,
const UString message 
)
static

Added the prefix header for a severity to a given message.

Parameters
[in]severitySeverity value.
[in]messageThe message to which the header shall be prepended.
Returns
The complete message string with header included.

◆ Enums()

static const Names & ts::Severity::Enums ( )
static

An enumeration to use severity values on the command line for instance.

Returns
A constant reference to the enumeration data.

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