ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/cvsroot/Net-XMPP2/lib/Net/XMPP2/Error/IQ.pm
Revision: 1.1
Committed: Thu Jul 5 17:33:59 2007 UTC (19 years, 3 months ago) by elmex
Branch: MAIN
CVS Tags: HEAD
Error occurred while calculating annotation data.
Log Message:
fixed some broken links in the documentation and moved errors
to seperate files.

File Contents

# Content
1 package Net::XMPP2::Error::IQ;
2 use Net::XMPP2::Error::Stanza;
3 our @ISA = qw/Net::XMPP2::Error::Stanza/;
4
5 =head1 NAME
6
7 Net::XMPP2::Error::IQ - IQ errors
8
9 Subclass of L<Net::XMPP2::Error::Stanza>
10
11 =cut
12
13 sub init {
14 my ($self) = @_;
15 my $node = $self->xml_node;
16
17 unless (defined $node) {
18 $self->{error_cond} = 'client-timeout';
19 $self->{error_type} = 'cancel';
20 return;
21 }
22
23 $self->SUPER::init;
24 }
25
26 =head2 METHODS
27
28 =over 4
29
30 =item B<condition ()>
31
32 Same as L<Net::XMPP2::Error::Stanza> except that
33 in case of a IQ timeout it returns:
34
35 'client-timeout'
36
37 =cut
38
39 sub string {
40 my ($self) = @_;
41
42 sprintf "iq error: %s/%s (type %s): %s",
43 $self->code || '',
44 $self->condition || '',
45 $self->type,
46 $self->text
47 }
48
49 =back
50
51 =cut
52
53
54 =head1 AUTHOR
55
56 Robin Redeker, C<< <elmex at ta-sa.org> >>, JID: C<< <elmex at jabber.org> >>
57
58 =head1 COPYRIGHT & LICENSE
59
60 Copyright 2007 Robin Redeker, all rights reserved.
61
62 This program is free software; you can redistribute it and/or modify it
63 under the same terms as Perl itself.
64
65 =cut
66
67 1; # End of Net::XMPP2