DolLogsCollector
class DolLogsCollector extends MessagesCollector (View source)
DolLogsCollector class
Properties
| protected string | $path | ||
| protected int | $maxnboflines | ||
| protected int | $nboflines |
Methods
Constructor
Return widget settings
Return collected data
Get the path to the logs file
Get logs
Get latest file lines
Search a string for log entries into the log file. Used when debug bar scan log file (very slow).
Get the log levels from psr/log.
Details
__construct(string $path = null, string $name = 'logs')
Constructor
getWidgets()
Return widget settings
@return array<string,array{icon?:string,indicator?:string,widget?:string,tooltip?:string|array{html:string,class:string},map:string,default:string}> Array
collect()
Return collected data
@return array{count:int,messages:string[]} Array of collected data
string
getLogsFile()
Get the path to the logs file
void
getStorageLogs(string $path)
Get logs
protected string[]
tailFile(string $file, int $lines)
Get latest file lines
list<array{level: string, line: string}>
getLogs(string $file)
Search a string for log entries into the log file. Used when debug bar scan log file (very slow).
array<string, string>
getLevels()
Get the log levels from psr/log.