ILIAS
release_5-3 Revision v5.3.23-19-g915713cf615
◀ ilDoc Overview
LogglyFormatter.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\Formatter
;
13
19
class
LogglyFormatter
extends
JsonFormatter
20
{
27
public
function
__construct
(
$batchMode
= self::BATCH_MODE_NEWLINES,
$appendNewline
=
false
)
28
{
29
parent::__construct(
$batchMode
,
$appendNewline
);
30
}
31
38
public
function
format
(
array
$record)
39
{
40
if
(isset($record[
"datetime"
]) && ($record[
"datetime"
] instanceof \
DateTime
)) {
41
$record[
"timestamp"
] = $record[
"datetime"
]->format(
"Y-m-d\TH:i:s.uO"
);
42
// TODO 2.0 unset the 'datetime' parameter, retained for BC
43
}
44
45
return
parent::format
($record);
46
}
47
}
DateTime
Monolog\Formatter
Definition:
ChromePHPFormatter.php:12
Monolog\Formatter\LogglyFormatter\format
format(array $record)
Appends the 'timestamp' parameter for indexing by Loggly.
Definition:
LogglyFormatter.php:38
Monolog\Formatter\LogglyFormatter
Encodes message information into JSON in a format compatible with Loggly.
Definition:
LogglyFormatter.php:19
array
Create styles array
The data for the language used.
Definition:
40duplicateStyle.php:19
Monolog\Formatter\JsonFormatter
Encodes whatever record data is passed to it as json.
Definition:
JsonFormatter.php:23
format
Write to Excel2007 format
Definition:
01pharSimple.php:78
Monolog\Formatter\JsonFormatter\$appendNewline
$appendNewline
Definition:
JsonFormatter.php:29
Monolog\Formatter\LogglyFormatter\__construct
__construct($batchMode=self::BATCH_MODE_NEWLINES, $appendNewline=false)
Overrides the default batch mode to new lines for compatibility with the Loggly bulk API...
Definition:
LogglyFormatter.php:27
Monolog\Formatter\JsonFormatter\$batchMode
$batchMode
Definition:
JsonFormatter.php:28
libs
composer
vendor
monolog
monolog
src
Monolog
Formatter
LogglyFormatter.php
Generated on Sat Jan 18 2025 19:01:05 for ILIAS by
1.8.13 (using
Doxyfile
)