line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package OpenTracing::Role::ContextReference; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
our $VERSION = 'v0.86.1'; |
4
|
|
|
|
|
|
|
|
5
|
3
|
|
|
3
|
|
473789
|
use Moo::Role; |
|
3
|
|
|
|
|
18284
|
|
|
3
|
|
|
|
|
16
|
|
6
|
3
|
|
|
3
|
|
2731
|
use MooX::Enumeration; |
|
3
|
|
|
|
|
8066
|
|
|
3
|
|
|
|
|
21
|
|
7
|
3
|
|
|
3
|
|
1808
|
use MooX::ProtectedAttributes; |
|
3
|
|
|
|
|
2390
|
|
|
3
|
|
|
|
|
19
|
|
8
|
3
|
|
|
3
|
|
1609
|
use MooX::Should; |
|
3
|
|
|
|
|
14649
|
|
|
3
|
|
|
|
|
17
|
|
9
|
|
|
|
|
|
|
|
10
|
3
|
|
|
3
|
|
1715
|
use OpenTracing::Types qw/SpanContext/; |
|
3
|
|
|
|
|
317295
|
|
|
3
|
|
|
|
|
28
|
|
11
|
3
|
|
|
3
|
|
2066
|
use Types::Standard qw/Enum/; |
|
3
|
|
|
|
|
9
|
|
|
3
|
|
|
|
|
23
|
|
12
|
|
|
|
|
|
|
|
13
|
3
|
|
|
3
|
|
7287
|
use constant CHILD_OF => 'child_of'; |
|
3
|
|
|
|
|
9
|
|
|
3
|
|
|
|
|
208
|
|
14
|
3
|
|
|
3
|
|
29
|
use constant FOLLOWS_FROM => 'follows_from'; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
556
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
protected_has reference_type => ( |
17
|
|
|
|
|
|
|
is => 'ro', |
18
|
|
|
|
|
|
|
should => Enum[ CHILD_OF, FOLLOWS_FROM ], |
19
|
|
|
|
|
|
|
); |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
has referenced_context => ( |
22
|
|
|
|
|
|
|
is => 'ro', |
23
|
|
|
|
|
|
|
should => SpanContext, |
24
|
|
|
|
|
|
|
required => 1, |
25
|
|
|
|
|
|
|
reader => 'get_referenced_context', |
26
|
|
|
|
|
|
|
); |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
sub new_child_of { |
29
|
1
|
|
|
1
|
1
|
1803
|
$_[0]->new( |
30
|
|
|
|
|
|
|
reference_type => CHILD_OF, |
31
|
|
|
|
|
|
|
referenced_context => $_[1], |
32
|
|
|
|
|
|
|
) |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
1
|
|
|
1
|
1
|
3168
|
sub type_is_child_of { $_[0]->reference_type eq CHILD_OF } |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
sub new_follows_from { |
38
|
1
|
|
|
1
|
1
|
3966
|
$_[0]->new( |
39
|
|
|
|
|
|
|
reference_type => FOLLOWS_FROM, |
40
|
|
|
|
|
|
|
referenced_context => $_[1], |
41
|
|
|
|
|
|
|
) |
42
|
|
|
|
|
|
|
} |
43
|
|
|
|
|
|
|
|
44
|
1
|
|
|
1
|
1
|
965
|
sub type_is_follows_from { $_[0]->reference_type eq FOLLOWS_FROM } |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
BEGIN { |
49
|
3
|
|
|
3
|
|
20
|
with 'OpenTracing::Interface::ContextReference' |
50
|
|
|
|
|
|
|
} |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
|
54
|
|
|
|
|
|
|
1; |