libqi  1.14
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
fileloghandler.hpp
1 /*
2  * Copyright (c) 2012 Aldebaran Robotics. All rights reserved.
3  * Use of this source code is governed by a BSD-style license that can be
4  * found in the COPYING file.
5  */
6 
7 #pragma once
8 #ifndef _LIBQI_QI_LOG_FILELOGHANDLER_HPP_
9 #define _LIBQI_QI_LOG_FILELOGHANDLER_HPP_
10 
11 # include <qi/log.hpp>
12 # include <string>
13 
14 namespace qi {
15  namespace log {
16  class PrivateFileLogHandler;
17 
21  class QI_API FileLogHandler
22  {
23  public:
24  explicit FileLogHandler(const std::string& filePath);
25  virtual ~FileLogHandler();
26 
27  void log(const qi::log::LogLevel verb,
28  const qi::os::timeval date,
29  const char *category,
30  const char *msg,
31  const char *file,
32  const char *fct,
33  const int line);
34 
35  private:
37  PrivateFileLogHandler* _private;
38  }; // !FileLogHandler
39 
40  }; // !log
41 }; // !qi
42 
43 #endif // _LIBQI_QI_LOG_FILELOGHANDLER_HPP_