1 """Error classes.
2 """
3 __docformat__ = 'restructuredtext en'
4
5
7 """Exception raised whenever there is a problem with connection between
8 Skype4Py and Skype client. It can be subscripted in which case following
9 information can be obtained:
10
11 +-------+------------------------------+
12 | Index | Meaning |
13 +=======+==============================+
14 | 0 | (unicode) Error description. |
15 +-------+------------------------------+
16 """
17
19 """__init__.
20
21 :Parameters:
22 errstr : unicode
23 Error description.
24 """
25 Exception.__init__(self, str(errstr))
26
27
29 """Raised whenever Skype client reports an error back to Skype4Py. It can be
30 subscripted in which case following information can be obtained:
31
32 +-------+------------------------------+
33 | Index | Meaning |
34 +=======+==============================+
35 | 0 | (int) Error code. See below. |
36 +-------+------------------------------+
37 | 1 | (unicode) Error description. |
38 +-------+------------------------------+
39
40 :see: https://developer.skype.com/Docs/ApiDoc/Error_codes for more information about
41 Skype error codes. Additionally an **error code 0** can be raised by Skype4Py
42 itself.
43 """
44
46 """__init__.
47
48 :Parameters:
49 errno : int
50 Error code.
51 errstr : unicode
52 Error description.
53 """
54 Exception.__init__(self, int(errno), str(errstr))
55
57 return '[Errno %d] %s' % (self[0], self[1])
58