| line |
true |
false |
branch |
|
124
|
0 |
8 |
unless (defined $file and length $file) |
|
127
|
3 |
5 |
if (ref $file) { } |
|
128
|
0 |
3 |
unless (ref $file eq 'GLOB' or UNIVERSAL::isa($file, 'IO::Handle')) |
|
139
|
0 |
5 |
$@ ? : |
|
140
|
0 |
5 |
if $options{'debug'} |
|
141
|
0 |
5 |
unless open $h, $mode, $file |
|
151
|
8 |
0 |
if (%options) |
|
154
|
0 |
25 |
if ($key eq 'debug' or $key eq 'skip_empty_lines') { } |
|
|
7 |
18 |
elsif ($key eq 'enclosure' or $key eq 'escape') { } |
|
|
7 |
11 |
elsif ($key eq 'delimiter') { } |
|
|
1 |
10 |
elsif ($key eq 'include_fields') { } |
|
|
8 |
2 |
elsif ($key eq 'field_aliases') { } |
|
|
1 |
1 |
elsif ($key eq 'field_normalizer') { } |
|
|
1 |
0 |
elsif ($key eq 'mutators') { } |
|
|
0 |
0 |
elsif ($key =~ /^(?:Text(?::|_)CSV|text_csv)[\._:](.+)$/) { } |
|
158
|
0 |
7 |
if (not defined $value or ref $value) |
|
164
|
0 |
7 |
if (not defined $value or ref $value or not length $value) |
|
171
|
0 |
1 |
if (ref $value ne 'ARRAY') |
|
177
|
0 |
8 |
if (ref $value ne 'HASH') |
|
183
|
0 |
1 |
if (ref $value ne 'CODE') |
|
189
|
0 |
1 |
if (ref $value ne 'HASH') |
|
194
|
2 |
0 |
if (defined $mutator) |
|
195
|
0 |
2 |
unless (ref $mutator eq 'CODE') |
|
227
|
0 |
0 |
if ($err eq '2012') |
|
242
|
8 |
0 |
if (my $row = $self->{'text_csv'}->getline($self->{'h'})) { } |
|
246
|
0 |
64 |
unless (defined $name) |
|
250
|
0 |
64 |
unless (length $name) |
|
253
|
8 |
56 |
if ($opt_field_normalizer) |
|
256
|
64 |
0 |
if (%opt_field_aliases) |
|
258
|
8 |
56 |
if (defined $opt_field_aliases{$key}) |
|
262
|
6 |
58 |
if (%opt_include_fields and not exists $opt_include_fields{$name}) |
|
265
|
0 |
58 |
if (exists $self->{'field_cols'}{$name}) |
|
270
|
0 |
8 |
unless (%{$self->{'field_cols'};}) |
|
271
|
0 |
0 |
%opt_include_fields ? : |
|
274
|
1 |
7 |
if (%opt_include_fields) |
|
279
|
2 |
0 |
if (exists $self->{'field_cols'}{$key}) |
|
291
|
1 |
7 |
if (%opt_include_fields) |
|
294
|
0 |
2 |
unless (exists $self->{'field_cols'}{$name}) |
|
298
|
0 |
1 |
if (@missing) |
|
318
|
5 |
3 |
if ($self->{'own_h'}) |
|
341
|
0 |
8 |
unless ($result) |
|
364
|
27 |
9 |
if (my $csv_row = $self->{'text_csv'}->getline($self->{'h'})) { } |
|
365
|
0 |
27 |
if ($self->{'debug'}) |
|
375
|
124 |
74 |
if (defined $v) |
|
377
|
0 |
124 |
unless (length $v) |
|
385
|
3 |
24 |
if (my $mutators = $self->{'mutators'}) |
|
387
|
6 |
0 |
if (exists $row{$k}) |
|
388
|
6 |
0 |
if (my $mutator = $mutators->{$k}) |
|
494
|
0 |
1 |
unless seek $self->{'h'}, 0, 0 |