DebugLoggerInterface.php 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Component\HttpKernel\Log;
  11. use Symfony\Component\HttpFoundation\Request;
  12. /**
  13. * DebugLoggerInterface.
  14. *
  15. * @author Fabien Potencier <fabien@symfony.com>
  16. */
  17. interface DebugLoggerInterface
  18. {
  19. /**
  20. * Returns an array of logs.
  21. *
  22. * @return array<array{
  23. * channel: ?string,
  24. * context: array<string, mixed>,
  25. * message: string,
  26. * priority: int,
  27. * priorityName: string,
  28. * timestamp: int,
  29. * timestamp_rfc3339: string,
  30. * }>
  31. */
  32. public function getLogs(?Request $request = null);
  33. /**
  34. * Returns the number of errors.
  35. *
  36. * @return int
  37. */
  38. public function countErrors(?Request $request = null);
  39. /**
  40. * Removes all log records.
  41. *
  42. * @return void
  43. */
  44. public function clear();
  45. }