projects
/
dcpomatic.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
More string -> boost::filesystem::path.
[dcpomatic.git]
/
src
/
lib
/
log.h
diff --git
a/src/lib/log.h
b/src/lib/log.h
index 2e5d69a0828a77d508b3cc1d4c122898204eb027..6a911b13f29c64dd742beef1eee54a6b6429e0e1 100644
(file)
--- a/
src/lib/log.h
+++ b/
src/lib/log.h
@@
-17,8
+17,8
@@
*/
*/
-#ifndef D
VD
OMATIC_LOG_H
-#define D
VD
OMATIC_LOG_H
+#ifndef D
CP
OMATIC_LOG_H
+#define D
CP
OMATIC_LOG_H
/** @file src/log.h
* @brief A very simple logging class.
/** @file src/log.h
* @brief A very simple logging class.
@@
-26,14
+26,16
@@
#include <string>
#include <boost/thread/mutex.hpp>
#include <string>
#include <boost/thread/mutex.hpp>
+#include <boost/filesystem.hpp>
/** @class Log
* @brief A very simple logging class.
*/
/** @class Log
* @brief A very simple logging class.
*/
-class Log
+class Log
: public boost::noncopyable
{
public:
Log ();
{
public:
Log ();
+ virtual ~Log () {}
enum Level {
STANDARD = 0,
enum Level {
STANDARD = 0,
@@
-45,6
+47,7
@@
public:
void microsecond_log (std::string m, Level l = STANDARD);
void set_level (Level l);
void microsecond_log (std::string m, Level l = STANDARD);
void set_level (Level l);
+ void set_level (std::string l);
protected:
/** mutex to protect the log */
protected:
/** mutex to protect the log */
@@
-60,12
+63,12
@@
private:
class FileLog : public Log
{
public:
class FileLog : public Log
{
public:
- FileLog (
std::string
file);
+ FileLog (
boost::filesystem::path
file);
private:
void do_log (std::string m);
/** filename to write to */
private:
void do_log (std::string m);
/** filename to write to */
-
std::string
_file;
+
boost::filesystem::path
_file;
};
#endif
};
#endif