NAME

App::Embra::Role::Logging - adds logging methods to a class

VERSION

version 0.001

DESCRIPTION

This role adds some basic logging methods to its implementer. It provides a logger attributer which handles all of the standard log methods.

ATTRIBUTES

log_prefix

A string to prefix to all logged messages. Defaults to the empty string.

logger

The object which handles all the logging. It must accept any of Log::Any's logging methods.

METHODS

_build_log_prefix

say $app_embra_role_logging->_build_log_prefix;

Returns the log prefix. Present only so it can be modified by implementors with around.

_build_logger

my $logger = $app_embra_role_logging->_build_logger;

Returns a new instance of Log::Any. Present only so it can be modified by implementors with around.

AUTHOR

Daniel Holz <dgholz@gmail.com>

COPYRIGHT AND LICENSE

This software is copyright (c) 2015 by Daniel Holz.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.