line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package XML::XMetaL::Utilities::Filter::Element;
|
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
7000
|
use base 'XML::XMetaL::Utilities::Filter::Base';
|
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
624
|
|
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
use strict;
|
6
|
|
|
|
|
|
|
use warnings;
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
use Carp;
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
use XML::XMetaL::Utilities qw(:dom_node_types);
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
use constant TRUE => 1;
|
13
|
|
|
|
|
|
|
use constant FALSE => 0;
|
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
# Constructor is in super class
|
16
|
|
|
|
|
|
|
|
17
|
|
|
|
|
|
|
sub accept {
|
18
|
|
|
|
|
|
|
my ($self, $node) = @_;
|
19
|
|
|
|
|
|
|
my $accept = eval {$node->{nodeType} == DOMELEMENT ? TRUE : FALSE;};
|
20
|
|
|
|
|
|
|
croak $@ if $@;
|
21
|
|
|
|
|
|
|
return $accept;
|
22
|
|
|
|
|
|
|
}
|
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |