2015-09-17 23:11:18 -04:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace Aviat\Ion\Di;
|
|
|
|
|
2015-11-13 16:31:01 -05:00
|
|
|
use Psr\Log\LoggerInterface;
|
|
|
|
|
2015-10-09 22:29:59 -04:00
|
|
|
/**
|
|
|
|
* Interface for the Dependency Injection Container
|
|
|
|
*/
|
2015-09-17 23:11:18 -04:00
|
|
|
interface ContainerInterface extends \Interop\Container\ContainerInterface {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Add a value to the container
|
|
|
|
*
|
|
|
|
* @param string $key
|
|
|
|
* @param mixed $value
|
|
|
|
* @return ContainerInterface
|
|
|
|
*/
|
|
|
|
public function set($key, $value);
|
2015-11-13 16:31:01 -05:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Add a logger to the Container
|
|
|
|
*
|
|
|
|
* @param LoggerInterface $logger
|
|
|
|
* @param string $key The logger 'channel'
|
|
|
|
*/
|
|
|
|
public function setLogger(LoggerInterface $logger, $key = 'default');
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Retrieve a logger for the selected channel
|
|
|
|
*
|
|
|
|
* @param string $key The logger to retreive
|
|
|
|
* @return LoggerInterface|null
|
|
|
|
*/
|
|
|
|
public function getLogger($key = 'default');
|
2015-09-17 23:11:18 -04:00
|
|
|
}
|