Events/Listener.pm

filter: Statementstmt 75.0% 9 / 12 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 40.0% 2 / 5 Podpod 100% 2 / 2 totaltotal 68.4% 13 / 19 CC 1 SCAR 3.5
CC
1
Cov
75%
handle
2.0
handler
2.0
__ANON__
1.1
CRAP 1.4
« Events/Dispatcher.pm ↑ Summary Events.pm »
1 package Mojolicious::Plugin::Events::Listener;
2 1 ▶use Mojo::Base -base;
Subroutine BEGIN: called CC=1 SCAR=0.0
3  
4 1 ▶use Mojo::Server;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 0 ▶has app => sub { Mojo::Server->new->build_app('Mojo::HelloWorld') };
Subroutine __ANON__: not called CC=1 SCAR=1.2
7 1 has event => 'default';
8  
9 =head2 handle
10  
11 Handle event
12  
13 =cut
14  
15 0 ▶sub handle {
Subroutine handle: not called CC=1 SCAR=6.9
Pod documented
16 0 return shift->handler(@_);
17 }
18  
19 =head2 handler
20  
21 Define the handler
22  
23 =cut
24  
25 0 ▶sub handler {
Subroutine handler: not called CC=1 SCAR=6.9
Pod documented
26 0 warn "Implement in subclass."
27 }
28  
29 1 1;
« Events/Dispatcher.pm ↑ Summary Events.pm »