Elemental/Node.pm

filter: Statementstmt 69.2% 18 / 26 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 83.3% 5 / 6 Podpod n/a totaltotal 71.8% 23 / 32 CC 2 SCAR 8.9
CC
2
Cov
69%
__ANON__
6.0
BEGIN
1.0
BEGIN
1.0
CRAP 2.4
« Elemental/Transformer/Gatherer.pm ↑ Summary Elemental/Selectors.pm »
1 package Pod::Elemental::Node 0.103006;
2 # ABSTRACT: a thing with Pod::Elemental::Nodes as children
3  
4 13 ▶use Moose::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 13 ▶use namespace::autoclean;
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 13 ▶use MooseX::Types;
Subroutine BEGIN: called CC=1 SCAR=0.0
9 13 ▶use MooseX::Types::Moose qw(ArrayRef);
Subroutine BEGIN: called CC=1 SCAR=0.0
10  
11 13 requires 'as_pod_string';
12 13 requires 'as_debug_string';
13  
14 #pod =head1 OVERVIEW
15 #pod
16 #pod Classes that include Pod::Elemental::Node represent collections of child
17 #pod Pod::Elemental::Paragraphs. This includes Pod documents, Pod5 regions, and
18 #pod nested Pod elements produced by the Gatherer transformer.
19 #pod
20 #pod =attr children
21 #pod
22 #pod This attribute is an arrayref of
23 #pod L<Pod::Elemental::Node|Pod::Elemental::Node>-performing objects, and represents
24 #pod elements contained by an object.
25 #pod
26 #pod =cut
27  
28 has children => (
29 is => 'rw',
30 isa => ArrayRef[ role_type('Pod::Elemental::Paragraph') ],
31 required => 1,
32 9 ▶ default => sub { [] },
Subroutine __ANON__: called CC=1 SCAR=0.0
33 13 );
34  
35 0 ▶around as_debug_string => sub {
Subroutine __ANON__: not called CC=2 SCAR=17.9
36 0 my ($orig, $self) = @_;
37  
38 0 my $str = $self->$orig;
39  
40 0 my @children = map { $_->as_debug_string } @{ $self->children };
41 0 s/^/ /sgm for @children;
42  
43 0 $str = join "\n", $str, @children;
44  
45 0 return $str;
46 13 };
47  
48 13 1;
49  
50 __END__
« Elemental/Transformer/Gatherer.pm ↑ Summary Elemental/Selectors.pm »