blib/lib/Set/Associate/Role/RefillItems.pm

filter: Statementstmt 90.6% 29 / 32 Branchbran 50.0% 3 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 88.8% 8 / 9 Podpod n/a totaltotal 85.1% 40 / 47 CC 4 SCAR 8.4
CC
4
Cov
84%
__ANON__
4.7
__ANON__
2.0
BEGIN
1.0
CRAP 2.3
« blib/lib/Set/Associate/RefillItems.pm ↑ Summary blib/lib/Set/Associate/NewKey/HashMD5.pm »
1 19 ▶use 5.006;
Subroutine BEGIN: called CC=1 SCAR=0.0
2 19 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
3 19 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
4  
5 package Set::Associate::Role::RefillItems;
6  
7 # ABSTRACT: A data provider for Set::Associate
8  
9 19 our $VERSION = '0.004000';
10  
11 19 our $AUTHORITY = 'cpan:KENTNL'; # AUTHORITY
12  
13 19 ▶use MooseX::Role::Parameterized qw( parameter role requires );
Subroutine BEGIN: called CC=1 SCAR=0.0
14  
15 parameter can_get_next => (
16 isa => Bool =>,
17 is => rw =>,
18 24 ▶ default => sub { undef },
Subroutine __ANON__: called CC=1 SCAR=0.0
19 19 );
20  
21 parameter can_get_all => (
22 isa => Bool =>,
23 is => rw =>,
24 0 ▶ default => sub { undef },
Subroutine __ANON__: not called CC=1 SCAR=6.9
25 19 );
26  
27 parameter can_get_nth => (
28 isa => Bool =>,
29 ,
30 is => rw =>,
31 24 ▶ default => sub { undef },
Subroutine __ANON__: called CC=1 SCAR=0.0
32 19 );
33  
34 role {
35 24 ▶ my $p = shift;
Subroutine __ANON__: called CC=4 SCAR=15.5
36  
37 24 requires name =>;
38  
39 24 ▶ if ( $p->can_get_next ) {
Branch: 1 branch
BranchTrueFalseTotal
if ($p->can_get_next) 0 24 24
40 0 requires get_next =>;
41 }
42 24 ▶ if ( $p->can_get_all ) {
Branch: 1 branch
BranchTrueFalseTotal
if ($p->can_get_all) 24 0 24
43 24 requires get_all =>;
44 }
45 24 ▶ if ( $p->can_get_nth ) {
Branch: 1 branch
BranchTrueFalseTotal
if ($p->can_get_nth) 0 24 24
46 0 requires get_nth =>;
47 }
48  
49 19 };
50  
51 19 ▶no MooseX::Role::Parameterized;
Subroutine BEGIN: called CC=1 SCAR=0.0
52  
53 19 1;
54  
55 __END__
56  
57 =pod
58  
59 =encoding UTF-8
60  
61 =head1 NAME
62  
63 Set::Associate::Role::RefillItems - A data provider for Set::Associate
64  
65 =head1 VERSION
66  
67 version 0.004000
68  
69 =head1 AUTHOR
70  
71 Kent Fredric <kentnl@cpan.org>
72  
73 =head1 COPYRIGHT AND LICENSE
74  
75 This software is copyright (c) 2015 by Kent Fredric <kentfredric@gmail.com>.
76  
77 This is free software; you can redistribute it and/or modify it under
78 the same terms as the Perl 5 programming language system itself.
79  
80 =cut
« blib/lib/Set/Associate/RefillItems.pm ↑ Summary blib/lib/Set/Associate/NewKey/HashMD5.pm »