Serial output logger based on the LoggerInterface

Dependencies:   LoggerInterface

Files at this revision

API Documentation at this revision

Comitter:
Sille Van Landschoot
Date:
Sun Apr 02 13:51:38 2017 +0200
Parent:
4:17b744fb14da
Commit message:
solve merge bug in LogIt.h

Changed in this revision

LogIt.h Show annotated file Show diff for this revision Revisions of this file
diff -r 17b744fb14da -r 8cd22c68d239 LogIt.h
--- a/LogIt.h	Sun Apr 02 13:23:40 2017 +0200
+++ b/LogIt.h	Sun Apr 02 13:51:38 2017 +0200
@@ -6,20 +6,21 @@
 class LogIt : public Log::LoggerInterface
 {
     public:
-    LogIt(Serial* serial);
-    void emergency(char* message, ...);
-    void alert(char* message, ...);
-    void critical(char* message, ...);
-    void error(char* message, ...);
-    void warning(char* message, ...);
-    void notice(char* message, ...);
-    void info(char* message, ...);
-    void debug(char* message, ...);
-    void log(Level level, char* message, ...);
+    LogIt(mbed::Serial* serial);
+    void emergency(const char* message, ...);
+    void alert(const char* message, ...);
+    void critical(const char* message, ...);
+    void error(const char* message, ...);
+    void warning(const char* message, ...);
+    void notice(const char* message, ...);
+    void info(const char* message, ...);
+    void debug(const char* message, ...);
+    void log(Level level, const char* message, ...);
 
     void setLevel(Level level);
 
     protected:
-    Serial* serial;
+    void log(Level level, const char* message,  va_list args);
+    mbed::Serial* serial;
     Level level; // minimum level to log
 };