line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Message::Passing::Role::HasTimeoutAndReconnectAfter; |
2
|
3
|
|
|
3
|
|
1651
|
use Moo::Role; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
17
|
|
3
|
3
|
|
|
3
|
|
2176
|
use MooX::Types::MooseLike::Base qw/ Num /; |
|
3
|
|
|
|
|
14077
|
|
|
3
|
|
|
|
|
261
|
|
4
|
3
|
|
|
3
|
|
34
|
use namespace::clean -except => 'meta'; |
|
3
|
|
|
|
|
7
|
|
|
3
|
|
|
|
|
20
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
has timeout => ( |
7
|
|
|
|
|
|
|
isa => Num, |
8
|
|
|
|
|
|
|
is => 'ro', |
9
|
|
|
|
|
|
|
default => sub { 30 }, |
10
|
|
|
|
|
|
|
); |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
has reconnect_after => ( |
13
|
|
|
|
|
|
|
isa => Num, |
14
|
|
|
|
|
|
|
is => 'ro', |
15
|
|
|
|
|
|
|
default => sub { 2 }, |
16
|
|
|
|
|
|
|
); |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
1; |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=head1 NAME |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
Message::Passing::Role::HasTimeoutAndReconnectAfter |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=head1 DESCRIPTION |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
Adds a C<timeout> and a C<reconnect_after> attributes to your class. |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
=head1 METHODS |
29
|
|
|
|
|
|
|
|
30
|
|
|
|
|
|
|
=head2 timeout |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=head2 reconnect_after |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
=head1 AUTHOR, COPYRIGHT AND LICENSE |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
See L<Message::Passing>. |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
=cut |