line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package XML::XMetaL::Mock::DOMText::Tie;
|
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
118260
|
use Tie::Hash;
|
|
2
|
|
|
|
|
1501
|
|
|
2
|
|
|
|
|
225
|
|
4
|
2
|
|
|
2
|
|
13
|
use base 'Tie::StdHash';
|
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
2124
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
sub TIEHASH {
|
7
|
3
|
|
|
3
|
|
6
|
my ($class, $object) = @_;
|
8
|
3
|
|
|
|
|
11
|
my $self = bless $object, $class;
|
9
|
3
|
|
|
|
|
9
|
return $self;
|
10
|
|
|
|
|
|
|
}
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
sub STORE {
|
13
|
5
|
|
|
5
|
|
1572
|
my ($self, $key, $value) = @_;
|
14
|
5
|
|
|
|
|
11
|
$self->{$key} = $value;
|
15
|
5
|
100
|
|
|
|
41
|
$self->{length} = length $value if $key eq 'data';
|
16
|
|
|
|
|
|
|
}
|
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
package XML::XMetaL::Mock::DOMText;
|
19
|
|
|
|
|
|
|
|
20
|
2
|
|
|
2
|
|
60
|
use 5.008;
|
|
2
|
|
|
|
|
32
|
|
|
2
|
|
|
|
|
86
|
|
21
|
2
|
|
|
2
|
|
12
|
use strict;
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
97
|
|
22
|
2
|
|
|
2
|
|
13
|
use warnings;
|
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
102
|
|
23
|
|
|
|
|
|
|
|
24
|
2
|
|
|
2
|
|
13
|
use Carp;
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
168
|
|
25
|
2
|
|
|
2
|
|
1910
|
use Hash::Util qw(lock_keys);
|
|
2
|
|
|
|
|
8787
|
|
|
2
|
|
|
|
|
19
|
|
26
|
2
|
|
|
2
|
|
836
|
use Tie::Hash;
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
51
|
|
27
|
|
|
|
|
|
|
|
28
|
2
|
|
|
2
|
|
10
|
use base ('Tie::StdHash', 'XML::XMetaL::Mock::DOMNode');
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
3265
|
|
29
|
|
|
|
|
|
|
|
30
|
2
|
|
|
2
|
|
551
|
use constant TRUE => 1;
|
|
2
|
|
|
|
|
8
|
|
|
2
|
|
|
|
|
220
|
|
31
|
2
|
|
|
2
|
|
11
|
use constant FALSE => 0;
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
2203
|
|
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
our @keys = qw(
|
34
|
|
|
|
|
|
|
data
|
35
|
|
|
|
|
|
|
length
|
36
|
|
|
|
|
|
|
);
|
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
sub new {
|
40
|
3
|
|
|
3
|
0
|
35
|
my ($class, %args) = @_;
|
41
|
|
|
|
|
|
|
#my $self;
|
42
|
3
|
|
|
|
|
6
|
my %self;
|
43
|
|
|
|
|
|
|
my $self; |
44
|
3
|
|
|
|
|
6
|
eval {
|
45
|
3
|
|
|
|
|
5
|
my %properties;
|
46
|
3
|
|
|
|
|
16
|
@properties{@keys} = @args{@keys};
|
47
|
3
|
|
|
|
|
33
|
my $super_class = $class->SUPER::new(%args);
|
48
|
3
|
|
|
|
|
34
|
%properties = (
|
49
|
|
|
|
|
|
|
%$super_class,
|
50
|
|
|
|
|
|
|
%properties,
|
51
|
|
|
|
|
|
|
);
|
52
|
3
|
|
|
|
|
26
|
tie %self, 'XML::XMetaL::Mock::DOMText::Tie', \%properties; |
53
|
3
|
|
33
|
|
|
20
|
$self = bless \%self, ref($class) || $class; |
54
|
3
|
|
|
|
|
28
|
lock_keys(%$self, keys %$self); |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
};
|
57
|
3
|
50
|
|
|
|
918
|
croak $@ if $@;
|
58
|
3
|
|
|
|
|
14
|
return $self;
|
59
|
|
|
|
|
|
|
}
|
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
1;
|
64
|
|
|
|
|
|
|
__END__
|