line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package MediaWiki::DumpFile; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
our $VERSION = '0.2.2'; |
4
|
|
|
|
|
|
|
|
5
|
4
|
|
|
4
|
|
183367
|
use warnings; |
|
4
|
|
|
|
|
18
|
|
|
4
|
|
|
|
|
150
|
|
6
|
4
|
|
|
4
|
|
23
|
use strict; |
|
4
|
|
|
|
|
8
|
|
|
4
|
|
|
|
|
149
|
|
7
|
4
|
|
|
4
|
|
23
|
use Carp qw(croak); |
|
4
|
|
|
|
|
10
|
|
|
4
|
|
|
|
|
1664
|
|
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
sub new { |
10
|
3
|
|
|
3
|
0
|
47
|
my ($class, %files) = @_; |
11
|
3
|
|
|
|
|
8
|
my $self = {}; |
12
|
|
|
|
|
|
|
|
13
|
3
|
|
|
|
|
10
|
bless($self, $class); |
14
|
|
|
|
|
|
|
|
15
|
3
|
|
|
|
|
11
|
return $self; |
16
|
|
|
|
|
|
|
} |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub sql { |
19
|
2
|
50
|
|
2
|
1
|
83
|
if (! defined($_[1])) { |
20
|
0
|
|
|
|
|
0
|
croak "must specify a filename or open filehandle"; |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
2
|
|
|
|
|
869
|
require MediaWiki::DumpFile::SQL; |
24
|
|
|
|
|
|
|
|
25
|
2
|
|
|
|
|
21
|
return MediaWiki::DumpFile::SQL->new($_[1]); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
sub pages { |
29
|
1
|
|
|
1
|
1
|
8
|
my ($class, @args) = @_; |
30
|
1
|
|
|
|
|
773
|
require MediaWiki::DumpFile::Pages; |
31
|
|
|
|
|
|
|
|
32
|
0
|
|
|
|
|
0
|
return MediaWiki::DumpFile::Pages->new(@args); |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
sub fastpages { |
36
|
1
|
50
|
|
1
|
1
|
10
|
if (! defined($_[1])) { |
37
|
0
|
|
|
|
|
0
|
croak "must specify a filename or open filehandle"; |
38
|
|
|
|
|
|
|
} |
39
|
|
|
|
|
|
|
|
40
|
1
|
|
|
|
|
818
|
require MediaWiki::DumpFile::FastPages; |
41
|
|
|
|
|
|
|
|
42
|
0
|
|
|
|
|
|
return MediaWiki::DumpFile::FastPages->new($_[1]); |
43
|
|
|
|
|
|
|
} |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
1; |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
__END__ |