LoggerChannelFactoryInterface.php 729 B

1234567891011121314151617181920212223242526272829303132
  1. <?php
  2. namespace Drupal\Core\Logger;
  3. use Psr\Log\LoggerInterface;
  4. /**
  5. * Logger channel factory interface.
  6. */
  7. interface LoggerChannelFactoryInterface {
  8. /**
  9. * Retrieves the registered logger for the requested channel.
  10. *
  11. * @return \Drupal\Core\Logger\LoggerChannelInterface
  12. * The registered logger for this channel.
  13. */
  14. public function get($channel);
  15. /**
  16. * Adds a logger to all the channels.
  17. *
  18. * @param \Psr\Log\LoggerInterface $logger
  19. * The PSR-3 logger to add.
  20. * @param int $priority
  21. * The priority of the logger being added.
  22. *
  23. * @see \Symfony\Component\HttpKernel\DependencyInjection\LoggerPass
  24. */
  25. public function addLogger(LoggerInterface $logger, $priority = 0);
  26. }