line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package MR::IProto::Error; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
=head1 NAME |
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
MR::IProto::Error - iproto error |
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
=head1 DESCRIPTION |
8
|
|
|
|
|
|
|
|
9
|
|
|
|
|
|
|
Instance of this class is returned instead of L |
10
|
|
|
|
|
|
|
if error was occured. |
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
=cut |
13
|
|
|
|
|
|
|
|
14
|
1
|
|
|
1
|
|
6
|
use Mouse; |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
9
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
=head1 PUBLIC ATTRIBUTES |
17
|
|
|
|
|
|
|
|
18
|
|
|
|
|
|
|
=over |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
=item error |
21
|
|
|
|
|
|
|
|
22
|
|
|
|
|
|
|
Error string. |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
=cut |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
has error => ( |
27
|
|
|
|
|
|
|
is => 'ro', |
28
|
|
|
|
|
|
|
isa => 'Str', |
29
|
|
|
|
|
|
|
required => 1, |
30
|
|
|
|
|
|
|
); |
31
|
|
|
|
|
|
|
|
32
|
|
|
|
|
|
|
=item errno |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
Integer value of C<$!>. |
35
|
|
|
|
|
|
|
|
36
|
|
|
|
|
|
|
=cut |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
has errno => ( |
39
|
|
|
|
|
|
|
is => 'ro', |
40
|
|
|
|
|
|
|
isa => 'Int', |
41
|
|
|
|
|
|
|
); |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=item request |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
Instance of L. |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
=cut |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
has request => ( |
50
|
|
|
|
|
|
|
is => 'ro', |
51
|
|
|
|
|
|
|
isa => 'MR::IProto::Request', |
52
|
|
|
|
|
|
|
required => 1, |
53
|
|
|
|
|
|
|
); |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=back |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=head1 PUBLIC METHODS |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
=over |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
=item is_error |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Always returns true. |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
=cut |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
sub is_error { |
68
|
0
|
|
|
0
|
1
|
|
return 1; |
69
|
|
|
|
|
|
|
} |
70
|
|
|
|
|
|
|
|
71
|
|
|
|
|
|
|
=item error_message |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
Error message text. |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
=cut |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
sub error_message { |
78
|
0
|
|
|
0
|
1
|
|
my ($self) = @_; |
79
|
0
|
|
|
|
|
|
return $self->error; |
80
|
|
|
|
|
|
|
} |
81
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
=back |
83
|
|
|
|
|
|
|
|
84
|
|
|
|
|
|
|
=cut |
85
|
|
|
|
|
|
|
|
86
|
1
|
|
|
1
|
|
778
|
no Mouse; |
|
1
|
|
|
|
|
8
|
|
|
1
|
|
|
|
|
6
|
|
87
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable(); |
88
|
|
|
|
|
|
|
|
89
|
|
|
|
|
|
|
1; |