OnixS C++ CME iLink 3 Binary Order Entry Handler 1.19.0
API Documentation
Loading...
Searching...
No Matches
LogSettings.h
Go to the documentation of this file.
1/*
2* Copyright Onix Solutions Limited [OnixS]. All rights reserved.
3*
4* This software owned by Onix Solutions Limited [OnixS] and is protected by copyright law
5* and international copyright treaties.
6*
7* Access to and use of the software is governed by the terms of the applicable OnixS Software
8* Services Agreement (the Agreement) and Customer end user license agreements granting
9* a non-assignable, non-transferable and non-exclusive license to use the software
10* for it's own data processing purposes under the terms defined in the Agreement.
11*
12* Except as otherwise granted within the terms of the Agreement, copying or reproduction of any part
13* of this source code or associated reference material to any other location for further reproduction
14* or redistribution, and any amendments to this copyright notice, are expressly prohibited.
15*
16* Any reproduction or redistribution for sale or hiring of the Software not in accordance with
17* the terms of the Agreement is a violation of copyright law.
18*/
19
20#pragma once
21
22#include <string>
23
25
26namespace OnixS {
27namespace CME {
28namespace iLink3 {
29
31 struct LogLevel
32 {
33 enum Enum
34 {
36 Error = 0,
37
40
42 Info = 2,
43
45 Trace = 3,
46
48 Debug = 4,
49
52 };
53
55 ONIXS_ILINK3_EXPORTED static std::string toString(Enum type);
56
58 ONIXS_ILINK3_EXPORTED static Enum parse(const std::string& value);
59 };
60
61
64 {
65 enum Enum
66 {
69
73
76 };
77
79 ONIXS_ILINK3_EXPORTED static std::string toString(Enum type);
80
82 ONIXS_ILINK3_EXPORTED static Enum parse(std::string value);
83 };
84
87 {
88 using Type = typename std::underlying_type<LogSettings::Enum>::type;
89 return static_cast<LogSettings::Enum>(static_cast<Type>(a) | static_cast<Type>(b));
90 }
91}
92}
93}
#define ONIXS_ILINK3_EXPORTED
Definition Compiler.h:145
LogSettings::Enum operator|(LogSettings::Enum a, LogSettings::Enum b)
Typed logical operator helper.
Definition LogSettings.h:86
Represents the severity level of log messages.
Definition LogSettings.h:32
static Enum parse(const std::string &value)
Parses a log level from its textual representation.
static std::string toString(Enum type)
@ Max
The most verbose level.
Definition LogSettings.h:51
@ Info
General informational messages about normal operation.
Definition LogSettings.h:42
@ Warning
A potentially harmful situation that deserves attention.
Definition LogSettings.h:39
@ Error
A serious error that prevents normal execution.
Definition LogSettings.h:36
@ Trace
Fine-grained events for tracing control flow and state.
Definition LogSettings.h:45
@ Debug
Detailed diagnostic information useful during development and testing.
Definition LogSettings.h:48
static Enum parse(std::string value)
Parses options from the textual representation.
static std::string toString(Enum type)
@ Default
Default log settings.
Definition LogSettings.h:75
@ TraceToFile
Trace to the log file.
Definition LogSettings.h:68
@ TraceToConsole
Duplicate log messages to console.
Definition LogSettings.h:72