Log::ger::Layout::Pattern - Pattern layout
version 0.009
use Log::ger::Layout 'Pattern', format => '%d (%F:%L)> %m'; use Log::ger;
Known placeholder in format string:
%c Category of the logging event %C Fully qualified package (or class) name of the caller %d Current date in ISO8601 format (YYYY-MM-DD<T>hh:mm:ss) (localtime) %D Current date in ISO8601 format (YYYY-MM-DD<T>hh:mm:ss) (GMT) %F File where the logging event occurred %H Hostname (if Sys::Hostname is available) %l Fully qualified name of the calling method followed by the callers source the file name and line number between parentheses. %L Line number within the file where the log statement was issued %m The message to be logged %M Method or function where the logging request was issued %n Newline (OS-independent) %p Level ("priority")of the logging event %P pid of the current process %r Number of seconds elapsed from program start to logging event %R Number of seconds elapsed from last logging event to current logging event %T A stack trace of functions called %% A literal percent (%) sign %_{vmsize} Process virtual memory size, in KB. Currently works on Linux only. Value is cached for 1 second.
Regex or arrayref. When producing caller or stack trace information, will pass this to Devel::Caller::Util's caller() or callers().
caller()
callers()
Log::ger::Layout::Pattern::Multiline
Modelled after Log::Log4perl::Layout::PatternLayout but note that full compatibility or feature parity is not a goal. See also Log::Log4perl::Tiny.
Log::ger
Log::ger::Layout::LTSV
perlancar <perlancar@cpan.org>
This software is copyright (c) 2024, 2021, 2020, 2019, 2017 by perlancar <perlancar@cpan.org>.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.
To install Log::ger::Layout::Pattern, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Log::ger::Layout::Pattern
CPAN shell
perl -MCPAN -e shell install Log::ger::Layout::Pattern
For more information on module installation, please visit the detailed CPAN module installation guide.