| 1 | <?php |
||
| 12 | final class InMemoryLogger extends AbstractLogger implements LoggerInterface |
||
| 13 | { |
||
| 14 | use MessageInterpolationTrait; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * @var ArrayObject |
||
| 18 | */ |
||
| 19 | private $logs; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Construct a new instance of the logger. |
||
| 23 | * |
||
| 24 | * @param ArrayObject $logs Container for log entries. |
||
| 25 | */ |
||
| 26 | public function __construct(ArrayObject $logs) |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Logs with an arbitrary level. |
||
| 33 | * |
||
| 34 | * @param string $level A valid RFC-5424 log level. |
||
| 35 | * @param string $message The base log message. |
||
| 36 | * @param array $context Any extraneous information that does not fit well in a string. |
||
| 37 | * |
||
| 38 | * @return void |
||
| 39 | */ |
||
| 40 | public function log($level, $message, array $context = []) |
||
| 48 | } |
||
| 49 |