File Coverage

lib/OODoc/Text/SubSubSection.pm
Criterion Covered Total %
statement 15 27 55.5
branch 0 6 0.0
condition 0 7 0.0
subroutine 5 10 50.0
pod 4 5 80.0
total 24 55 43.6


line stmt bran cond sub pod time code
1             # Copyrights 2003-2021 by [Mark Overmeer].
2             # For other contributors see ChangeLog.
3             # See the manual pages for details on the licensing terms.
4             # Pod stripped from pm file by OODoc 2.02.
5             # This code is part of perl distribution OODoc. It is licensed under the
6             # same terms as Perl itself: https://spdx.org/licenses/Artistic-2.0.html
7              
8             package OODoc::Text::SubSubSection;
9 1     1   7 use vars '$VERSION';
  1         2  
  1         54  
10             $VERSION = '2.02';
11              
12 1     1   6 use base 'OODoc::Text::Structure';
  1         2  
  1         98  
13              
14 1     1   7 use strict;
  1         2  
  1         17  
15 1     1   4 use warnings;
  1         2  
  1         38  
16              
17 1     1   6 use Log::Report 'oodoc';
  1         1  
  1         6  
18              
19              
20             sub init($)
21 0     0 0   { my ($self, $args) = @_;
22 0   0       $args->{type} ||= 'Subsubsection';
23 0 0 0       $args->{container} ||= delete $args->{subsection} or panic;
24 0   0       $args->{level} ||= 3;
25              
26 0 0         $self->SUPER::init($args)
27             or return;
28              
29 0           $self;
30             }
31              
32             sub findEntry($)
33 0     0 1   { my ($self, $name) = @_;
34 0 0         $self->name eq $name ? $self : ();
35             }
36              
37             #--------------
38              
39 0     0 1   sub subsection() { shift->container }
40              
41              
42 0     0 1   sub chapter() { shift->subsection->chapter }
43              
44             sub path()
45 0     0 1   { my $self = shift;
46 0           $self->subsection->path . '/' . $self->name;
47             }
48              
49             1;