line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package IO::Compress::Deflate ; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
require 5.006 ; |
4
|
|
|
|
|
|
|
|
5
|
16
|
|
|
16
|
|
39040
|
use strict ; |
|
16
|
|
|
|
|
95
|
|
|
16
|
|
|
|
|
419
|
|
6
|
16
|
|
|
16
|
|
71
|
use warnings; |
|
16
|
|
|
|
|
32
|
|
|
16
|
|
|
|
|
360
|
|
7
|
16
|
|
|
16
|
|
4945
|
use bytes; |
|
16
|
|
|
|
|
135
|
|
|
16
|
|
|
|
|
80
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
require Exporter ; |
10
|
|
|
|
|
|
|
|
11
|
16
|
|
|
16
|
|
6346
|
use IO::Compress::RawDeflate 2.206 (); |
|
16
|
|
|
|
|
342
|
|
|
16
|
|
|
|
|
569
|
|
12
|
16
|
|
|
16
|
|
95
|
use IO::Compress::Adapter::Deflate 2.206 ; |
|
16
|
|
|
|
|
183
|
|
|
16
|
|
|
|
|
2715
|
|
13
|
|
|
|
|
|
|
|
14
|
16
|
|
|
16
|
|
4381
|
use IO::Compress::Zlib::Constants 2.206 ; |
|
16
|
|
|
|
|
258
|
|
|
16
|
|
|
|
|
1398
|
|
15
|
16
|
|
|
16
|
|
100
|
use IO::Compress::Base::Common 2.206 qw(); |
|
16
|
|
|
|
|
270
|
|
|
16
|
|
|
|
|
5977
|
|
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
our ($VERSION, @ISA, @EXPORT_OK, %EXPORT_TAGS, %DEFLATE_CONSTANTS, $DeflateError); |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
$VERSION = '2.206'; |
21
|
|
|
|
|
|
|
$DeflateError = ''; |
22
|
|
|
|
|
|
|
|
23
|
|
|
|
|
|
|
@ISA = qw(IO::Compress::RawDeflate Exporter); |
24
|
|
|
|
|
|
|
@EXPORT_OK = qw( $DeflateError deflate ) ; |
25
|
|
|
|
|
|
|
%EXPORT_TAGS = %IO::Compress::RawDeflate::DEFLATE_CONSTANTS ; |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
push @{ $EXPORT_TAGS{all} }, @EXPORT_OK ; |
28
|
|
|
|
|
|
|
Exporter::export_ok_tags('all'); |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
sub new |
32
|
|
|
|
|
|
|
{ |
33
|
172
|
|
|
172
|
1
|
157667
|
my $class = shift ; |
34
|
|
|
|
|
|
|
|
35
|
172
|
|
|
|
|
599
|
my $obj = IO::Compress::Base::Common::createSelfTiedObject($class, \$DeflateError); |
36
|
172
|
|
|
|
|
655
|
return $obj->_create(undef, @_); |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
sub deflate |
40
|
|
|
|
|
|
|
{ |
41
|
152
|
|
|
152
|
1
|
119825
|
my $obj = IO::Compress::Base::Common::createSelfTiedObject(undef, \$DeflateError); |
42
|
152
|
|
|
|
|
449
|
return $obj->_def(@_); |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
sub mkComp |
46
|
|
|
|
|
|
|
{ |
47
|
299
|
|
|
299
|
0
|
434
|
my $self = shift ; |
48
|
299
|
|
|
|
|
392
|
my $got = shift ; |
49
|
|
|
|
|
|
|
|
50
|
299
|
|
|
|
|
568
|
my ($obj, $errstr, $errno) = IO::Compress::Adapter::Deflate::mkCompObject1( |
51
|
|
|
|
|
|
|
$got->getValue('crc32'), |
52
|
|
|
|
|
|
|
$got->getValue('adler32'), |
53
|
|
|
|
|
|
|
$got->getValue('level'), |
54
|
|
|
|
|
|
|
$got->getValue('strategy') |
55
|
|
|
|
|
|
|
); |
56
|
|
|
|
|
|
|
|
57
|
299
|
50
|
|
|
|
796
|
return $self->saveErrorString(undef, $errstr, $errno) |
58
|
|
|
|
|
|
|
if ! defined $obj; |
59
|
|
|
|
|
|
|
|
60
|
299
|
|
|
|
|
1882
|
return $obj; |
61
|
|
|
|
|
|
|
} |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
sub mkHeader |
65
|
|
|
|
|
|
|
{ |
66
|
298
|
|
|
298
|
0
|
459
|
my $self = shift ; |
67
|
298
|
|
|
|
|
722
|
return ''; |
68
|
|
|
|
|
|
|
} |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
sub mkTrailer |
71
|
|
|
|
|
|
|
{ |
72
|
318
|
|
|
318
|
0
|
493
|
my $self = shift ; |
73
|
318
|
|
|
|
|
625
|
return ''; |
74
|
|
|
|
|
|
|
} |
75
|
|
|
|
|
|
|
|
76
|
|
|
|
|
|
|
sub mkFinalTrailer |
77
|
|
|
|
|
|
|
{ |
78
|
291
|
|
|
291
|
0
|
578
|
return ''; |
79
|
|
|
|
|
|
|
} |
80
|
|
|
|
|
|
|
|
81
|
|
|
|
|
|
|
sub getExtraParams |
82
|
|
|
|
|
|
|
{ |
83
|
323
|
|
|
323
|
0
|
485
|
my $self = shift ; |
84
|
323
|
|
|
|
|
830
|
return $self->getZlibParams(), |
85
|
|
|
|
|
|
|
} |
86
|
|
|
|
|
|
|
|
87
|
|
|
|
|
|
|
sub getInverseClass |
88
|
|
|
|
|
|
|
{ |
89
|
16
|
|
|
16
|
|
173
|
no warnings 'once'; |
|
16
|
|
|
|
|
51
|
|
|
16
|
|
|
|
|
1570
|
|
90
|
23
|
|
|
23
|
0
|
71
|
return ('IO::Uncompress::Inflate', |
91
|
|
|
|
|
|
|
\$IO::Uncompress::Inflate::InflateError); |
92
|
|
|
|
|
|
|
} |
93
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
sub getFileInfo |
95
|
|
|
|
|
|
|
{ |
96
|
102
|
|
|
102
|
0
|
137
|
my $self = shift ; |
97
|
102
|
|
|
|
|
126
|
my $params = shift; |
98
|
102
|
|
|
|
|
161
|
my $file = shift ; |
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
} |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
|
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
1; |
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
__END__ |