line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package XML::Grammar::FictionBase::Event; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
8
|
use strict; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
83
|
|
4
|
2
|
|
|
2
|
|
6
|
use warnings; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
112
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
|
7
|
2
|
|
|
2
|
|
7
|
use MooX 'late'; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
12
|
|
8
|
|
|
|
|
|
|
|
9
|
2
|
|
|
2
|
|
2510
|
use XML::Grammar::Fiction::FromProto::Node; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
275
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
has 'type' => (isa => "Str", is => "ro"); |
12
|
|
|
|
|
|
|
has 'tag' => (isa => "Maybe[Str]", is => "ro", predicate => '_has_tag',); |
13
|
|
|
|
|
|
|
has 'elem' => (is => "ro"); |
14
|
|
|
|
|
|
|
has 'tag_elem' => (is => "ro"); |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
our $VERSION = '0.14.11'; |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
sub is_tag_of_name |
19
|
|
|
|
|
|
|
{ |
20
|
0
|
|
|
0
|
1
|
|
my ($self, $name) = @_; |
21
|
|
|
|
|
|
|
|
22
|
0
|
|
0
|
|
|
|
return ($self->_has_tag() && ($self->tag() eq $name)); |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub is_open |
26
|
|
|
|
|
|
|
{ |
27
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
28
|
|
|
|
|
|
|
|
29
|
0
|
|
|
|
|
|
return ($self->type() eq "open"); |
30
|
|
|
|
|
|
|
} |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
sub is_open_or_close |
33
|
|
|
|
|
|
|
{ |
34
|
0
|
|
|
0
|
1
|
|
my $self = shift; |
35
|
|
|
|
|
|
|
|
36
|
0
|
|
0
|
|
|
|
return (($self->type() eq "open") || ($self->type() eq "close")); |
37
|
|
|
|
|
|
|
} |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
1; |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
__END__ |