| 1 | package Video::PlaybackMachine::Logger; | ||
| 2 | |||
| 3 | 2 | our $VERSION = '0.09'; # VERSION | |
| 4 | |||
| 5 | 2 | ▶ | use Moo::Role; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 6 | 2 | ▶ | use Log::Log4perl; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 7 | |||
| 8 | 2 | has 'logger' => ( | |
| 9 | 'is' => 'lazy', | ||
| 10 | 'handles' => [ qw/ trace debug info warn error fatal | ||
| 11 | is_trace is_debug is_info is_warn is_error is_fatal | ||
| 12 | logwarn logdie logconfess | ||
| 13 | / ] | ||
| 14 | ); | ||
| 15 | |||
| 16 | 3 | ▶ | sub _build_logger { |
|
Subroutine
_build_logger: called CC=1 SCAR=0.0
| |||
| 17 | 3 | my $self = shift; | |
| 18 | |||
| 19 | 3 | return Log::Log4perl->get_logger( ref $self ); | |
| 20 | } | ||
| 21 | |||
| 22 | 2 | ▶ | no Moo::Role; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 23 | |||
| 24 | 2 | 1; | |