Verzeichnisstruktur phpBB-3.2.0


Veröffentlicht
06.01.2017

So funktioniert es


Auf das letzte Element klicken. Dies geht jeweils ein Schritt zurück

Auf das Icon klicken, dies öffnet das Verzeichnis. Nochmal klicken schließt das Verzeichnis.
Auf den Verzeichnisnamen klicken, dies zeigt nur das Verzeichnis mit Inhalt an

      (Beispiel Datei-Icons)

Auf das Icon klicken um den Quellcode anzuzeigen

AbstractLogger.php

Zuletzt modifiziert: 09.10.2024, 12:57 - Dateigröße: 3.02 KiB


 001  <?php
 002   
 003  namespace Psr\Log;
 004   
 005  /**
 006   * This is a simple Logger implementation that other Loggers can inherit from.
 007   *
 008   * It simply delegates all log-level-specific methods to the `log` method to
 009   * reduce boilerplate code that a simple Logger that does the same thing with
 010   * messages regardless of the error level has to implement.
 011   */
 012  abstract class AbstractLogger implements LoggerInterface
 013  {
 014      /**
 015       * System is unusable.
 016       *
 017       * @param string $message
 018       * @param array  $context
 019       *
 020       * @return void
 021       */
 022      public function emergency($message, array $context = array())
 023      {
 024          $this->log(LogLevel::EMERGENCY, $message, $context);
 025      }
 026   
 027      /**
 028       * Action must be taken immediately.
 029       *
 030       * Example: Entire website down, database unavailable, etc. This should
 031       * trigger the SMS alerts and wake you up.
 032       *
 033       * @param string $message
 034       * @param array  $context
 035       *
 036       * @return void
 037       */
 038      public function alert($message, array $context = array())
 039      {
 040          $this->log(LogLevel::ALERT, $message, $context);
 041      }
 042   
 043      /**
 044       * Critical conditions.
 045       *
 046       * Example: Application component unavailable, unexpected exception.
 047       *
 048       * @param string $message
 049       * @param array  $context
 050       *
 051       * @return void
 052       */
 053      public function critical($message, array $context = array())
 054      {
 055          $this->log(LogLevel::CRITICAL, $message, $context);
 056      }
 057   
 058      /**
 059       * Runtime errors that do not require immediate action but should typically
 060       * be logged and monitored.
 061       *
 062       * @param string $message
 063       * @param array  $context
 064       *
 065       * @return void
 066       */
 067      public function error($message, array $context = array())
 068      {
 069          $this->log(LogLevel::ERROR, $message, $context);
 070      }
 071   
 072      /**
 073       * Exceptional occurrences that are not errors.
 074       *
 075       * Example: Use of deprecated APIs, poor use of an API, undesirable things
 076       * that are not necessarily wrong.
 077       *
 078       * @param string $message
 079       * @param array  $context
 080       *
 081       * @return void
 082       */
 083      public function warning($message, array $context = array())
 084      {
 085          $this->log(LogLevel::WARNING, $message, $context);
 086      }
 087   
 088      /**
 089       * Normal but significant events.
 090       *
 091       * @param string $message
 092       * @param array  $context
 093       *
 094       * @return void
 095       */
 096      public function notice($message, array $context = array())
 097      {
 098          $this->log(LogLevel::NOTICE, $message, $context);
 099      }
 100   
 101      /**
 102       * Interesting events.
 103       *
 104       * Example: User logs in, SQL logs.
 105       *
 106       * @param string $message
 107       * @param array  $context
 108       *
 109       * @return void
 110       */
 111      public function info($message, array $context = array())
 112      {
 113          $this->log(LogLevel::INFO, $message, $context);
 114      }
 115   
 116      /**
 117       * Detailed debug information.
 118       *
 119       * @param string $message
 120       * @param array  $context
 121       *
 122       * @return void
 123       */
 124      public function debug($message, array $context = array())
 125      {
 126          $this->log(LogLevel::DEBUG, $message, $context);
 127      }
 128  }
 129