ROOT
master
Reference Guide
Loading...
Searching...
No Matches
MnPrintImpl.cxx
Go to the documentation of this file.
1
#include "
Minuit2/MnPrint.h
"
2
3
using
ROOT::Minuit2::MnPrint
;
4
5
#ifndef USE_ROOT_ERROR
6
7
#include <iostream>
8
9
#ifndef MN_OS
10
#define MN_OS std::cerr
11
#endif
12
13
void
MnPrint::Impl
(
MnPrint::Verbosity
level,
const
std::string &s)
14
{
15
const
char
*label =
nullptr
;
16
switch
(level) {
17
case
MnPrint::eError
: label =
"[Error]"
;
break
;
18
case
MnPrint::eWarn
: label =
"[Warn]"
;
break
;
19
case
MnPrint::eInfo
: label =
"[Info]"
;
break
;
20
case
MnPrint::eDebug
: label =
"[Debug]"
;
break
;
21
case
MnPrint::eTrace
: label =
"[Trace]"
;
break
;
22
}
23
if
(label)
24
MN_OS
<< label <<
" "
<< s << std::endl;
25
}
26
27
#else
// use ROOT error reporting system
28
29
#include "
TError.h
"
30
#include <sstream>
31
32
void
MnPrint::Impl
(
MnPrint::Verbosity
level,
const
std::string &s)
33
{
34
switch
(level) {
35
case
MnPrint::eError
:
::Error
(
"Minuit2"
,
"%s"
, s.c_str());
break
;
36
case
MnPrint::eWarn
:
::Warning
(
"Minuit2"
,
"%s"
, s.c_str());
break
;
37
case
MnPrint::eInfo
:
::Info
(
"Minuit2"
,
"%s"
, s.c_str());
break
;
38
case
MnPrint::eDebug
:
::Info
(
"Minuit2"
,
"%s"
, s.c_str());
break
;
39
case
MnPrint::eTrace
:
::Info
(
"Minuit2"
,
"%s"
, s.c_str());
break
;
40
}
41
}
42
43
#endif
// USE_ROOT_ERROR
MN_OS
#define MN_OS
Definition
MnPrintImpl.cxx:10
MnPrint.h
TError.h
Warning
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
Definition
TError.cxx:252
ROOT::Minuit2::MnPrint
Definition
MnPrint.h:69
ROOT::Minuit2::MnPrint::eError
static constexpr auto eError
Definition
MnPrint.h:75
ROOT::Minuit2::MnPrint::eTrace
static constexpr auto eTrace
Definition
MnPrint.h:79
ROOT::Minuit2::MnPrint::Verbosity
Verbosity
Definition
MnPrint.h:72
ROOT::Minuit2::MnPrint::Verbosity::Info
@ Info
ROOT::Minuit2::MnPrint::Verbosity::Error
@ Error
ROOT::Minuit2::MnPrint::eWarn
static constexpr auto eWarn
Definition
MnPrint.h:76
ROOT::Minuit2::MnPrint::eInfo
static constexpr auto eInfo
Definition
MnPrint.h:77
ROOT::Minuit2::MnPrint::Impl
static void Impl(Verbosity level, const std::string &s)
Definition
MnPrintImpl.cxx:13
ROOT::Minuit2::MnPrint::eDebug
static constexpr auto eDebug
Definition
MnPrint.h:78
math
minuit2
src
MnPrintImpl.cxx
ROOTmaster - Reference Guide Generated on Sat Dec 5 2026 03:19:56 (GVA Time) using Doxygen 1.10.0