XMLStream: add a forever parameter to process(), defaulting to True, to select whether we want to stop the event loop after a disconnection

This commit is contained in:
Emmanuel Gil Peyrot
2015-02-28 14:04:42 +01:00
parent 0ef3fa2703
commit 632b7b4afe
3 changed files with 17 additions and 7 deletions

View File

@@ -53,7 +53,8 @@ Running the event loop
:meth:`.XMLStream.process` is only a thin wrapper on top of
``loop.run_forever()`` (if ``timeout`` is provided then it will
only run for this amount of time).
only run for this amount of time, and if ``forever`` is False it will
run until disconnection).
Therefore you can handle the event loop in any way you like
instead of using ``process()``.