You are here

trait LoggerAwareTrait in Service Container 7.2

Same name and namespace in other branches
  1. 7 lib/Psr/Log/LoggerAwareTrait.php \Psr\Log\LoggerAwareTrait

Basic Implementation of LoggerAwareInterface.

Hierarchy

File

lib/Psr/Log/LoggerAwareTrait.php, line 8

Namespace

Psr\Log
View source
trait LoggerAwareTrait {

  /** @var LoggerInterface */
  protected $logger;

  /**
   * Sets a logger.
   *
   * @param LoggerInterface $logger
   */
  public function setLogger(LoggerInterface $logger) {
    $this->logger = $logger;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
LoggerAwareTrait::$logger protected property @var LoggerInterface
LoggerAwareTrait::setLogger public function Sets a logger.