File Coverage

blib/lib/Pod/Simple/PullParserToken.pm
Criterion Covered Total %
statement 9 11 81.8
branch n/a
condition 0 3 0.0
subroutine 6 7 85.7
pod 5 6 83.3
total 20 27 74.0


line stmt bran cond sub pod time code
1             package Pod::Simple::PullParserToken;
2             # Base class for tokens gotten from Pod::Simple::PullParser's $parser->get_token
3             our @ISA = ();
4             our $VERSION = '3.45';
5 10     10   73 use strict;
  10         19  
  10         1860  
6              
7             sub new { # Class->new('type', stuff...); ## Overridden in derived classes anyway
8 0     0 0 0 my $class = shift;
9 0   0     0 return bless [@_], ref($class) || $class;
10             }
11              
12 698     698 1 8436 sub type { $_[0][0] } # Can't change the type of an object
13 51     51 1 326 sub dump { Pod::Simple::pretty( [ @{ $_[0] } ] ) }
  51         183  
14              
15 357     357 1 1521 sub is_start { $_[0][0] eq 'start' }
16 212     212 1 838 sub is_end { $_[0][0] eq 'end' }
17 336     336 1 1082 sub is_text { $_[0][0] eq 'text' }
18              
19             1;
20             __END__