MtPolicyd/Plugin/Role/PluginChain.pm

filter: Statementstmt 92.8% 13 / 14 Branchbran 50.0% 1 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 3 / 3 Podpod n/a totaltotal 89.4% 17 / 19 CC 2 SCAR 4.5
CC
2
Cov
88%
__ANON__
2.1
BEGIN
1.0
BEGIN
1.0
CRAP 1.6
« MtPolicyd/Plugin.pm ↑ Summary MtPolicyd/Plugin/Result.pm »
1 package Mail::MtPolicyd::Plugin::Role::PluginChain;
2  
3 3 ▶use Moose::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 3 our $VERSION = '1.11'; # VERSION
6 # ABSTRACT: role for plugins to support a nested plugin chain
7  
8 3 ▶use Mail::MtPolicyd::PluginChain;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 has 'chain' => (
11 is => 'ro',
12 isa => 'Maybe[Mail::MtPolicyd::PluginChain]',
13 lazy => 1,
14 default => sub {
15 1 ▶ my $self = shift;
Subroutine __ANON__: called CC=2 SCAR=7.6
16 1 ▶ if( defined $self->Plugin ) {
Branch: 1 branch
BranchTrueFalseTotal
if (defined $self->Plugin) 1 0 1
17 1 return Mail::MtPolicyd::PluginChain->new_from_config(
18 $self->vhost_name,
19 $self->Plugin,
20 );
21 }
22 0 return;
23 },
24 3 );
25 3 has 'Plugin' => ( is => 'rw', isa => 'Maybe[HashRef]' );
26  
27 3 1;
28  
29  
30 __END__
31 =pod
32  
33 =head1 NAME
34  
35 Mail::MtPolicyd::Plugin::Role::PluginChain - role for plugins to support a nested plugin chain
36  
37 =head1 VERSION
38  
39 version 1.11
40  
41 =head1 AUTHOR
42  
43 Markus Benning <ich@markusbenning.de>
44  
45 =head1 COPYRIGHT AND LICENSE
46  
47 This software is Copyright (c) 2014 by Markus Benning <ich@markusbenning.de>.
48  
49 This is free software, licensed under:
50  
51 The GNU General Public License, Version 2, June 1991
52  
53 =cut
54  
« MtPolicyd/Plugin.pm ↑ Summary MtPolicyd/Plugin/Result.pm »