02 Aug 2021 15:11:51 UTC
- Distribution: Log-Any
- Module version: 1.710
- Source (raw)
- Browse (raw)
- How to Contribute
- Issues (7)
- Testers (3528 / 0 / 0)
- KwaliteeBus factor: 3
- 84.53% Coverage
- License: perl_5
- Activity24 month
- Download (54.57KB)
- MetaCPAN Explorer
- Subscribe to distribution
- This version
- Latest version++ed by:23 non-PAUSE usersPREACTION 💯 Doug Bell
- COPYRIGHT AND LICENSE
Log::Any::Adapter::Util - Common utility functions for Log::Any
Returns a list of all logging method. E.g. "trace", "info", etc.
Returns a list of detection methods. E.g. "is_trace", "is_info", etc.
Returns a list of logging and detection methods (but not aliases).
Returns key/value pairs mapping aliases to "official" names. E.g. "err" maps to "error".
Returns a list of logging alias names. These are the keys from "log_level_aliases".
Returns a list of detection aliases. E.g. "is_err", "is_fatal", etc.
Given a level name (or alias), returns the numeric value described above under log level constants. E.g. "err" would return 3.
Given a reference, returns a one-line Data::Dumper dump with keys sorted.
Given a method name, a code reference and a package name, installs the code reference as a method in the package.
Given a class name, attempts to load it via require unless the class already has a constructor available. Throws an error on failure. Used internally and may become private in the future.
Slurp a file. Does *not* apply any layers. Used for testing and may become private in the future.
Compares dump_one_line results for two references. Also takes a test label as a third argument. Used for testing and may become private in the future.
Nothing is exported by default.
:levelstag is included in the import list, the following numeric constants will be imported:
EMERGENCY => 0 ALERT => 1 CRITICAL => 2 ERROR => 3 WARNING => 4 NOTICE => 5 INFO => 6 DEBUG => 7 TRACE => 8
Jonathan Swartz <firstname.lastname@example.org>
David Golden <email@example.com>
Doug Bell <firstname.lastname@example.org>
Daniel Pittman <email@example.com>
Stephen Thirlwall <firstname.lastname@example.org>
This software is copyright (c) 2017 by Jonathan Swartz, David Golden, and Doug Bell.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.