Version 1
[yaffs-website] / web / core / lib / Drupal / Core / Logger / LoggerChannelFactoryInterface.php
diff --git a/web/core/lib/Drupal/Core/Logger/LoggerChannelFactoryInterface.php b/web/core/lib/Drupal/Core/Logger/LoggerChannelFactoryInterface.php
new file mode 100644 (file)
index 0000000..a75678a
--- /dev/null
@@ -0,0 +1,32 @@
+<?php
+
+namespace Drupal\Core\Logger;
+
+use Psr\Log\LoggerInterface;
+
+/**
+ * Logger channel factory interface.
+ */
+interface LoggerChannelFactoryInterface {
+
+  /**
+   * Retrieves the registered logger for the requested channel.
+   *
+   * @return \Drupal\Core\Logger\LoggerChannelInterface
+   *   The registered logger for this channel.
+   */
+  public function get($channel);
+
+  /**
+   * Adds a logger to all the channels.
+   *
+   * @param \Psr\Log\LoggerInterface $logger
+   *   The PSR-3 logger to add.
+   * @param int $priority
+   *   The priority of the logger being added.
+   *
+   * @see \Drupal\Core\DependencyInjection\Compiler\RegisterLoggersPass
+   */
+  public function addLogger(LoggerInterface $logger, $priority = 0);
+
+}