line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Video::Info::FOO; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
20633
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
65
|
|
4
|
|
|
|
|
|
|
our $VERSION = '0.00'; |
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
5
|
use base qw(Video::Info); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
1005
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
####################################### |
9
|
|
|
|
|
|
|
# use this to define your custom |
10
|
|
|
|
|
|
|
# get/set methods. if they really |
11
|
|
|
|
|
|
|
# belong in Video::Info, let me know |
12
|
|
|
|
|
|
|
####################################### |
13
|
|
|
|
|
|
|
use Class::MakeMethods::Emulator::MethodMaker |
14
|
1
|
|
|
|
|
14
|
get_set => [qw( )], |
15
|
1
|
|
|
1
|
|
185
|
; |
|
1
|
|
|
|
|
3
|
|
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
####################################### |
18
|
|
|
|
|
|
|
# leave this intact, add any extra |
19
|
|
|
|
|
|
|
# init stuff you need (maybe a get/set |
20
|
|
|
|
|
|
|
# method?). feel free to override |
21
|
|
|
|
|
|
|
# init_attributes() |
22
|
|
|
|
|
|
|
####################################### |
23
|
|
|
|
|
|
|
sub init { |
24
|
1
|
|
|
1
|
0
|
3
|
my $self = shift; |
25
|
1
|
|
|
|
|
4
|
my %param = @_; |
26
|
1
|
|
|
|
|
9
|
$self->init_attributes(@_); |
27
|
1
|
|
|
|
|
11
|
return $self; |
28
|
|
|
|
|
|
|
} |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
####################################### |
31
|
|
|
|
|
|
|
# Obtain the filehandle and extract the |
32
|
|
|
|
|
|
|
# properties from the file. this is |
33
|
|
|
|
|
|
|
# the core function of the module |
34
|
|
|
|
|
|
|
####################################### |
35
|
|
|
|
|
|
|
sub probe { |
36
|
1
|
|
|
1
|
0
|
49
|
my $self = shift; |
37
|
|
|
|
|
|
|
|
38
|
1
|
|
|
|
|
4
|
my $fh = $self->handle; ## inherited from Video::Info |
39
|
|
|
|
|
|
|
|
40
|
1
|
|
|
|
|
936
|
while(<$fh>){ |
41
|
|
|
|
|
|
|
#parse it! |
42
|
|
|
|
|
|
|
} |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
##################################### |
45
|
|
|
|
|
|
|
#return 1 for a successful parse |
46
|
|
|
|
|
|
|
##################################### |
47
|
1
|
|
|
|
|
8
|
return 1; |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
1; |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
__END__ |