LoggerInterface inspired by PHP PSR-3
Fork of LoggerInterface by
LoggerInterface.h
- Committer:
- sillevl
- Date:
- 2016-11-24
- Revision:
- 0:13d1767f0c98
- Child:
- 1:8ee5fd3c1bf1
File content as of revision 0:13d1767f0c98:
#include <stdarg.h> namespace Log; class LoggerInterface { public: /** * System is unusable. * * @param string $message */ void emergency(char* message, ...) = null; /** * Action must be taken immediately. * * Example: Entire website down, database unavailable, etc. This should * trigger the SMS alerts and wake you up. * * @param string $message */ void alert(char* message, ...) = null; /** * Critical conditions. * * Example: Application component unavailable, unexpected exception. * * @param string $message */ void critical(char* message, ...) = null; /** * Runtime errors that do not require immediate action but should typically * be logged and monitored. * * @param string $message */ void error(char* message, ...) = null; /** * Exceptional occurrences that are not errors. * * Example: Use of deprecated APIs, poor use of an API, undesirable things * that are not necessarily wrong. * * @param string $message */ void warning(char* message, ...) = null; /** * Normal but significant events. * * @param string $message */ void notice(char* message, ...) = null; /** * Interesting events. * * Example: User logs in, SQL logs. * * @param string $message */ void info(char* message, ...) = null; /** * Detailed debug information. * * @param string $message */ void debug(char* message, ...) = null; /** * Logs with an arbitrary level. * * @param mixed $level * @param string $message */ void log(Level level, char* message, ...) = null; }