ILIAS  release_5-4 Revision v5.4.26-12-gabc799a52e6
WhatFailureGroupHandler.php
Go to the documentation of this file.
1 <?php
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 
12 namespace Monolog\Handler;
13 
21 {
25  public function handle(array $record)
26  {
27  if ($this->processors) {
28  foreach ($this->processors as $processor) {
29  $record = call_user_func($processor, $record);
30  }
31  }
32 
33  foreach ($this->handlers as $handler) {
34  try {
35  $handler->handle($record);
36  } catch (\Exception $e) {
37  // What failure?
38  } catch (\Throwable $e) {
39  // What failure?
40  }
41  }
42 
43  return false === $this->bubble;
44  }
45 
49  public function handleBatch(array $records)
50  {
51  if ($this->processors) {
52  $processed = array();
53  foreach ($records as $record) {
54  foreach ($this->processors as $processor) {
55  $processed[] = call_user_func($processor, $record);
56  }
57  }
58  $records = $processed;
59  }
60 
61  foreach ($this->handlers as $handler) {
62  try {
63  $handler->handleBatch($records);
64  } catch (\Exception $e) {
65  // What failure?
66  } catch (\Throwable $e) {
67  // What failure?
68  }
69  }
70  }
71 }
$records
Definition: simple_test.php:22
handle(array $record)
{Handles a record.All records may be passed to this method, and the handler should discard those that...
Forwards records to multiple handlers.
Forwards records to multiple handlers suppressing failures of each handler and continuing through to ...
handleBatch(array $records)
{Handles a set of records at once.The records to handle (an array of record arrays)} ...
$handler