cpython (merge 3.4 -> default): Merge 3.4 (asyncio doc)

https://hg.python.org/cpython/rev/23342733dd7e changeset: 94386:23342733dd7e parent: 94384:7e6340e67618 parent: 94385:21010940f8c1 user: Victor Stinner <victor.stinner@gmail.com> date: Fri Jan 30 00:37:22 2015 +0100 summary: Merge 3.4 (asyncio doc) files: Doc/library/asyncio-sync.rst | 23 +++++++++++++++++++++++ 1 files changed, 23 insertions(+), 0 deletions(-) diff --git a/Doc/library/asyncio-sync.rst b/Doc/library/asyncio-sync.rst --- a/Doc/library/asyncio-sync.rst +++ b/Doc/library/asyncio-sync.rst @@ -4,6 +4,29 @@ Synchronization primitives ========================== +Locks: + +* :class:`Lock` +* :class:`Event` +* :class:`Condition` +* :class:`Semaphore` +* :class:`BoundedSemaphore` + +Queues: + +* :class:`Queue` +* :class:`PriorityQueue` +* :class:`LifoQueue` +* :class:`JoinableQueue` + +asyncio locks and queues API were designed to be close to classes of the +:mod:`threading` module (:class:`~threading.Lock`, :class:`~threading.Event`, +:class:`~threading.Condition`, :class:`~threading.Semaphore`, +:class:`~threading.BoundedSemaphore`) and the :mod:`queue` module +(:class:`~queue.Queue`, :class:`~queue.PriorityQueue`, +:class:`~queue.LifoQueue`), but they have no *timeout* parameter. The +:func:`asyncio.wait_for` function can be used to cancel a task after a timeout. + Locks ----- -- Repository URL: https://hg.python.org/cpython
participants (1)
-
victor.stinner