File Coverage

blib/lib/Pod/Elemental/Element/Pod5/Nonpod.pm
Criterion Covered Total %
statement 6 6 100.0
branch n/a
condition n/a
subroutine 2 2 100.0
pod n/a
total 8 8 100.0


line stmt bran cond sub pod time code
1             package Pod::Elemental::Element::Pod5::Nonpod 0.103006;
2             # ABSTRACT: a non-pod element in a Pod document
3              
4 11     11   70 use Moose;
  11         25  
  11         70  
5             with 'Pod::Elemental::Flat';
6             with 'Pod::Elemental::Autoblank';
7              
8             #pod =head1 OVERVIEW
9             #pod
10             #pod A Pod5::Nonpod element represents a hunk of non-Pod content found in a Pod
11             #pod document tree. It is equivalent to a
12             #pod L<Generic::Nonpod|Pod::Elemental::Element::Generic::Nonpod> element, with the
13             #pod following differences:
14             #pod
15             #pod =over 4
16             #pod
17             #pod =item * it includes L<Pod::Elemental::Autoblank>
18             #pod
19             #pod =item * when producing a pod string, it wraps the non-pod content in =cut/=pod
20             #pod
21             #pod =back
22             #pod
23             #pod =cut
24              
25 11     11   64365 use namespace::autoclean;
  11         23  
  11         94  
26              
27             sub as_pod_string {
28             my ($self) = @_;
29             return sprintf "=cut\n%s=pod\n", $self->content;
30             }
31              
32             __PACKAGE__->meta->make_immutable;
33              
34             1;
35              
36             __END__
37              
38             =pod
39              
40             =encoding UTF-8
41              
42             =head1 NAME
43              
44             Pod::Elemental::Element::Pod5::Nonpod - a non-pod element in a Pod document
45              
46             =head1 VERSION
47              
48             version 0.103006
49              
50             =head1 OVERVIEW
51              
52             A Pod5::Nonpod element represents a hunk of non-Pod content found in a Pod
53             document tree. It is equivalent to a
54             L<Generic::Nonpod|Pod::Elemental::Element::Generic::Nonpod> element, with the
55             following differences:
56              
57             =over 4
58              
59             =item * it includes L<Pod::Elemental::Autoblank>
60              
61             =item * when producing a pod string, it wraps the non-pod content in =cut/=pod
62              
63             =back
64              
65             =head1 PERL VERSION
66              
67             This library should run on perls released even a long time ago. It should work
68             on any version of perl released in the last five years.
69              
70             Although it may work on older versions of perl, no guarantee is made that the
71             minimum required version will not be increased. The version may be increased
72             for any reason, and there is no promise that patches will be accepted to lower
73             the minimum required perl.
74              
75             =head1 AUTHOR
76              
77             Ricardo SIGNES <cpan@semiotic.systems>
78              
79             =head1 COPYRIGHT AND LICENSE
80              
81             This software is copyright (c) 2022 by Ricardo SIGNES.
82              
83             This is free software; you can redistribute it and/or modify it under
84             the same terms as the Perl 5 programming language system itself.
85              
86             =cut