1<?php 2 3/** 4 * @see https://github.com/laminas/laminas-log for the canonical source repository 5 * @copyright https://github.com/laminas/laminas-log/blob/master/COPYRIGHT.md 6 * @license https://github.com/laminas/laminas-log/blob/master/LICENSE.md New BSD License 7 */ 8 9namespace Laminas\Log\Writer; 10 11use Laminas\Log\Filter\FilterInterface as Filter; 12use Laminas\Log\Formatter\FormatterInterface as Formatter; 13 14interface WriterInterface 15{ 16 /** 17 * Add a log filter to the writer 18 * 19 * @param int|string|Filter $filter 20 * @return WriterInterface 21 */ 22 public function addFilter($filter); 23 24 /** 25 * Set a message formatter for the writer 26 * 27 * @param string|Formatter $formatter 28 * @return WriterInterface 29 */ 30 public function setFormatter($formatter); 31 32 /** 33 * Write a log message 34 * 35 * @param array $event 36 * @return WriterInterface 37 */ 38 public function write(array $event); 39 40 /** 41 * Perform shutdown activities 42 * 43 * @return void 44 */ 45 public function shutdown(); 46} 47