line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Net::WAMP::Messages; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
5
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
23
|
|
4
|
1
|
|
|
1
|
|
4
|
use warnings; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
51
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
|
|
196
|
use constant MSGS => { |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
#Session |
9
|
|
|
|
|
|
|
HELLO => 1, |
10
|
|
|
|
|
|
|
WELCOME => 2, |
11
|
|
|
|
|
|
|
ABORT => 3, |
12
|
|
|
|
|
|
|
CHALLENGE => 4, |
13
|
|
|
|
|
|
|
AUTHENTICATE => 5, |
14
|
|
|
|
|
|
|
GOODBYE => 6, |
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
ERROR => 8, |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
#PubSub |
19
|
|
|
|
|
|
|
PUBLISH => 16, |
20
|
|
|
|
|
|
|
PUBLISHED => 17, |
21
|
|
|
|
|
|
|
SUBSCRIBE => 32, |
22
|
|
|
|
|
|
|
SUBSCRIBED => 33, |
23
|
|
|
|
|
|
|
UNSUBSCRIBE => 34, |
24
|
|
|
|
|
|
|
UNSUBSCRIBED => 35, |
25
|
|
|
|
|
|
|
EVENT => 36, |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
#RPC |
28
|
|
|
|
|
|
|
CALL => 48, |
29
|
|
|
|
|
|
|
CANCEL => 49, |
30
|
|
|
|
|
|
|
RESULT => 50, |
31
|
|
|
|
|
|
|
REGISTER => 64, |
32
|
|
|
|
|
|
|
REGISTERED => 65, |
33
|
|
|
|
|
|
|
UNREGISTER => 66, |
34
|
|
|
|
|
|
|
UNREGISTERED => 67, |
35
|
|
|
|
|
|
|
INVOCATION => 68, |
36
|
|
|
|
|
|
|
INTERRUPT => 69, |
37
|
|
|
|
|
|
|
YIELD => 70, |
38
|
1
|
|
|
1
|
|
5
|
}; |
|
1
|
|
|
|
|
2
|
|
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
my %NAMES; |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
sub get_type_number { |
43
|
4
|
|
|
4
|
0
|
8
|
my ($name) = @_; |
44
|
|
|
|
|
|
|
|
45
|
4
|
|
|
|
|
15
|
return 0 + MSGS()->{$name}; |
46
|
|
|
|
|
|
|
} |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
sub get_type { |
49
|
4
|
|
|
4
|
0
|
7
|
my ($number) = @_; |
50
|
|
|
|
|
|
|
|
51
|
4
|
100
|
|
|
|
8
|
%NAMES = (reverse %{ MSGS() }) if !%NAMES; |
|
1
|
|
|
|
|
21
|
|
52
|
|
|
|
|
|
|
|
53
|
4
|
|
|
|
|
11
|
return $NAMES{$number}; |
54
|
|
|
|
|
|
|
} |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
1; |