Przeglądaj źródła

Add API version to Logger class

Jordi Boggiano 12 lat temu
rodzic
commit
e2b412846d
1 zmienionych plików z 11 dodań i 1 usunięć
  1. 11 1
      src/Monolog/Logger.php

+ 11 - 1
src/Monolog/Logger.php

@@ -76,6 +76,16 @@ class Logger implements LoggerInterface
      */
     const EMERGENCY = 600;
 
+    /**
+     * Monolog API version
+     *
+     * This is only bumped when API breaks are done and should
+     * follow the major version of the library
+     *
+     * @var int
+     */
+    const API = 1;
+
     protected static $levels = array(
         100 => 'DEBUG',
         200 => 'INFO',
@@ -331,7 +341,7 @@ class Logger implements LoggerInterface
 
     /**
      * Gets all supported logging levels.
-     * 
+     *
      * @return array Assoc array with human-readable level names => level codes.
      */
     public static function getLevels()