Rialto  0.1
Rialto media pipeline API
IClientLogHandler.h
Go to the documentation of this file.
1 /*
2  * If not stated otherwise in this file or this component's LICENSE file the
3  * following copyright and licenses apply:
4  *
5  * Copyright 2024 Sky UK
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  * @file ILogHandler.h
20  *
21  * This file comprises the class definition of ILogHandler.
22  * An interface, which provides API of custom server manager logging handler
23  */
24 
25 #ifndef FIREBOLT_RIALTO_I_CLIENT_LOG_HANDLER_H_
26 #define FIREBOLT_RIALTO_I_CLIENT_LOG_HANDLER_H_
27 
37 #include <string>
38 
39 namespace firebolt::rialto
40 {
46 {
47 public:
48  IClientLogHandler() = default;
49  virtual ~IClientLogHandler() = default;
50  IClientLogHandler(const IClientLogHandler &) = delete;
51  IClientLogHandler &operator=(const IClientLogHandler &) = delete;
53  IClientLogHandler &operator=(IClientLogHandler &&) = delete;
54 
59  enum class Level
60  {
61  Fatal,
62  Error,
63  Warning,
64  Milestone,
65  Info,
66  Debug,
67  External
68  };
69 
81  virtual void log(Level level, const std::string &file, int line, const std::string &function,
82  const std::string &message) = 0;
83 };
84 } // namespace firebolt::rialto
85 
86 #endif // FIREBOLT_RIALTO_I_CLIENT_LOG_HANDLER_H_
firebolt::rialto::IClientLogHandler::log
virtual void log(Level level, const std::string &file, int line, const std::string &function, const std::string &message)=0
A callback method for every log item generated by the rialto client library.
firebolt::rialto::IClientLogHandler
IClientLogHandler allows the user to define their own log handler for any messages generated by the r...
Definition: IClientLogHandler.h:45
firebolt::rialto::IClientLogHandler::Level
Level
All possible log levels that could be used in the log callback.
Definition: IClientLogHandler.h:59