Package nbxmpp :: Module protocol :: Class Error

[hide private]
[frames] | no frames]

# Class Error

source code

Used to quickly transform received stanza into error reply

Instance Methods | [hide private]

__init__(self, node, error, reply=1) Create error reply basing on the received 'node' stanza and the 'error' error condition | source code

__dupstr__(self, dup1=None, dup2=None) Dummy function used as preventor of creating error node in reply to error node. I.e. you will not be able to serialise "double" error into string. | source code

Inherited from `Protocol`: `__setitem__`, `getError`, `getErrorCode`, `getErrorMsg`, `getFrom`, `getID`, `getProperties`, `getStatusConditions`, `getTimestamp`, `getTimestamp2`, `getTo`, `getType`, `setError`, `setFrom`, `setID`, `setTimestamp`, `setTo`, `setType`

Inherited from `simplexml.Node`: `__contains__`, `__delitem__`, `__getattr__`, `__getitem__`, `__str__`, `addChild`, `addData`, `clearData`, `delAttr`, `delChild`, `getAttr`, `getAttrs`, `getChildren`, `getData`, `getName`, `getNamespace`, `getParent`, `getPayload`, `getTag`, `getTagAttr`, `getTagData`, `getTags`, `has_attr`, `iterTags`, `lookup_nsp`, `setAttr`, `setData`, `setName`, `setNamespace`, `setParent`, `setPayload`, `setTag`, `setTagAttr`, `setTagData`

Inherited from `object`: `__delattr__`, `__format__`, `__getattribute__`, `__hash__`, `__new__`, `__reduce__`, `__reduce_ex__`, `__repr__`, `__setattr__`, `__sizeof__`, `__subclasshook__`

Class Variables | [hide private]

Inherited from `simplexml.Node`: `FORCE_NODE_RECREATION`

Properties | [hide private]

Inherited from `object`: `__class__`

Method Details | [hide private]

### __init__(self, node, error, reply=1)
(Constructor)

source code

Create error reply basing on the received 'node' stanza and the 'error' error condition

If the 'node' is not the received stanza but locally created ('to' and 'from' fields needs not swapping) specify the 'reply' argument as false.

Overrides: object.__init__

### __dupstr__(self, dup1=None, dup2=None)

source code

Dummy function used as preventor of creating error node in reply to error node. I.e. you will not be able to serialise "double" error into string.