lib/Spreadsheet/Reader/ExcelXML/XMLReader/WorkbookXML.pm

filter: Statementstmt 94.7% 18 / 19 Branchbran 75.0% 3 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 4 / 4 Podpod 100% 1 / 1 totaltotal 92.8% 26 / 28 CC 3 SCAR 7.1
CC
3
Cov
91%
load_unique_bits
3.1
BEGIN
1.0
BEGIN
1.0
CRAP 2.0
« lib/Spreadsheet/Reader/ExcelXML/XMLReader/NamedSharedStrings.pm ↑ Summary blib/lib/Spreadsheet/Reader/ExcelXML/Chartsheet.pm »
1 package Spreadsheet::Reader::ExcelXML::XMLReader::WorkbookXML;
2 6 our $AUTHORITY = 'cpan:JANDREW';
3 6 ▶use version; our $VERSION = version->declare('v0.16.8');
Subroutine BEGIN: called CC=1 SCAR=0.0
4 ###LogSD warn "You uncovered internal logging statements for Spreadsheet::Reader::ExcelXML::XMLReader::WorkbookXML-$VERSION";
5  
6 6 ▶use Moose::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 6 requires qw( has_progid progid good_load );
8 ###LogSD use Log::Shiras::Telephone;
9  
10 #########1 Dispatch Tables 3#########4#########5#########6#########7#########8#########9
11  
12  
13  
14 #########1 Public Attributes 3#########4#########5#########6#########7#########8#########9
15  
16  
17  
18 #########1 Public Methods 3#########4#########5#########6#########7#########8#########9
19  
20 8 ▶sub load_unique_bits{
Subroutine load_unique_bits: called CC=3 SCAR=11.2
Pod documented
21 8 my( $self, ) = @_;
22 ###LogSD my $phone = Log::Shiras::Telephone->new( name_space =>
23 ###LogSD $self->get_all_space . '::load_unique_bits', );
24 ###LogSD $phone->talk( level => 'debug', message => [
25 ###LogSD "Testing if the flat XML workbook opened correctly", $self->has_progid ] );
26  
27 # Check progid setting
28 8 ▶ if( !$self->has_progid ){
Branch: 2 branches
BranchTrueFalseTotal
if (not $self->has_progid) { } 5 3 8
elsif ($self->progid eq 'Excel.Sheet') { } 3 0 3
29 ###LogSD $phone->talk( level => 'warn', message => [
30 ###LogSD 'No progid recorded - bad xml base file' ] );
31 5 $self->good_load( 0 );
32 }elsif( $self->progid eq 'Excel.Sheet' ){
33 ###LogSD $phone->talk( level => 'debug', message => [
34 ###LogSD 'Found the correct progid: Excel.Sheet' ] );
35 3 $self->good_load( 1 );
36 }else{
37 ###LogSD $phone->talk( level => 'warn', message => [
38 ###LogSD 'Bad progid: ' . $self->progid ] );
39 0 $self->good_load( 0 );
40 }
41 8 return 1;
42 }
43  
44 #########1 Private Attributes 3#########4#########5#########6#########7#########8#########9
45  
46  
47  
48 #########1 Private Methods 3#########4#########5#########6#########7#########8#########9
49  
50  
51  
52 #########1 Phinish 3#########4#########5#########6#########7#########8#########9
53  
54 6 ▶no Moose::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
55 6 1;
56  
57 #########1 Documentation 3#########4#########5#########6#########7#########8#########9
58 __END__
« lib/Spreadsheet/Reader/ExcelXML/XMLReader/NamedSharedStrings.pm ↑ Summary blib/lib/Spreadsheet/Reader/ExcelXML/Chartsheet.pm »