LogHandler.cpp
Go to the documentation of this file.
1 //
3 // © Copyright 2022 SCHUNK Mobile Greifsysteme GmbH, Lauffen/Neckar Germany
4 // © Copyright 2022 FZI Forschungszentrum Informatik, Karlsruhe, Germany
5 //
6 // This file is part of the Schunk SVH Library.
7 //
8 // The Schunk SVH Library is free software: you can redistribute it and/or
9 // modify it under the terms of the GNU General Public License as published by
10 // the Free Software Foundation, either version 3 of the License, or (at your
11 // option) any later version.
12 //
13 // The Schunk SVH Library is distributed in the hope that it will be useful,
14 // but WITHOUT ANY WARRANTY; without even the implied warranty of
15 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
16 // Public License for more details.
17 //
18 // You should have received a copy of the GNU General Public License along with
19 // the Schunk SVH Library. If not, see <https://www.gnu.org/licenses/>.
20 //
22 
23 //----------------------------------------------------------------------
30 //----------------------------------------------------------------------
31 
32 #include <iostream>
33 
36 
37 namespace driver_svh {
38 void ShellLogHandler::log(const std::string& file,
39  const int line,
40  const std::string& name,
41  LogLevel level,
42  const std::string& msg)
43 {
44  std::cout << logLevelToString(level) << " " << name << " (" << file << ", line " << line
45  << "): " << msg << std::endl;
46 }
47 } // namespace driver_svh
std::string logLevelToString(const LogLevel level)
Definition: LogLevel.h:47
virtual void log(const std::string &file, const int line, const std::string &name, LogLevel level, const std::string &msg) override
Definition: LogHandler.cpp:38


schunk_svh_library
Author(s): Georg Heppner, Lars Pfotzer, Felix Exner, Johannes Mangler, Stefan Scherzinger, Pascal Becker
autogenerated on Fri Apr 14 2023 02:26:23