1<?php declare(strict_types=1); 2 3/* 4 * This file is part of the Monolog package. 5 * 6 * (c) Jordi Boggiano <j.boggiano@seld.be> 7 * 8 * For the full copyright and license information, please view the LICENSE 9 * file that was distributed with this source code. 10 */ 11 12namespace Monolog; 13 14use ArrayAccess; 15 16/** 17 * Monolog log record interface for forward compatibility with Monolog 3.0 18 * 19 * This is just present in Monolog 2.4+ to allow interoperable code to be written against 20 * both versions by type-hinting arguments as `array|\Monolog\LogRecord $record` 21 * 22 * Do not rely on this interface for other purposes, and do not implement it. 23 * 24 * @author Jordi Boggiano <j.boggiano@seld.be> 25 * @template-extends \ArrayAccess<'message'|'level'|'context'|'level_name'|'channel'|'datetime'|'extra'|'formatted', mixed> 26 * @phpstan-import-type Record from Logger 27 */ 28interface LogRecord extends \ArrayAccess 29{ 30 /** 31 * @phpstan-return Record 32 */ 33 public function toArray(): array; 34} 35