Highlife/Code.pm untested

filter: Statementstmt 0.0% 0 / 15 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 5 Podpod 0.0% 0 / 3 totaltotal 0.0% 0 / 23 CC 1 SCAR 6.9
CC
1
Cov
0%
new
2.0
_init
2.0
append
2.0
CRAP 2.0
1 package Parse::Highlife::Code;
2  
3 use strict;
4 use Parse::Highlife::Utils qw(params);
5  
6 sub new
7 {
8 my( $class, @args ) = @_;
9 my $self = bless {}, $class;
10 return $self -> _init( @args );
11 }
12  
13 sub _init
14 {
15 my( $self, @args ) = @_;
16 $self->{'source'} = ''; # the source code that is generated
17 return $self;
18 }
19  
20 sub append
21 {
22 my( $self, $string ) = @_;
23 $self->{'source'} .= $string;
24 return $self;
25 }
26  
27 1;