mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
bpo-33649: Add low-level APIs index. (GH-9364)
This commit is contained in:
parent
c6fd1c1c3a
commit
394374e30c
10 changed files with 571 additions and 31 deletions
|
@ -1,9 +1,9 @@
|
|||
.. currentmodule:: asyncio
|
||||
|
||||
|
||||
=====================
|
||||
High-level APIs Index
|
||||
=====================
|
||||
====================
|
||||
High-level API Index
|
||||
====================
|
||||
|
||||
This page lists all high-level async/await enabled asyncio APIs.
|
||||
|
||||
|
@ -16,6 +16,7 @@ await on multiple things with timeouts.
|
|||
|
||||
.. list-table::
|
||||
:widths: 50 50
|
||||
:class: full-width-table
|
||||
|
||||
* - :func:`run`
|
||||
- Create event loop, run a coroutine, close the loop.
|
||||
|
@ -36,7 +37,7 @@ await on multiple things with timeouts.
|
|||
- Shield from cancellation.
|
||||
|
||||
* - ``await`` :func:`wait`
|
||||
- Monitor for completeness.
|
||||
- Monitor for completion.
|
||||
|
||||
* - :func:`current_task`
|
||||
- Return the current Task.
|
||||
|
@ -47,6 +48,12 @@ await on multiple things with timeouts.
|
|||
* - :class:`Task`
|
||||
- Task object.
|
||||
|
||||
* - :func:`run_coroutine_threadsafe`
|
||||
- Schedule a coroutine from another OS thread.
|
||||
|
||||
* - ``for in`` :func:`as_completed`
|
||||
- Monitor for completion with a ``for`` loop.
|
||||
|
||||
|
||||
.. rubric:: Examples
|
||||
|
||||
|
@ -72,6 +79,7 @@ implement connection pools, and pub/sub patterns.
|
|||
|
||||
.. list-table::
|
||||
:widths: 50 50
|
||||
:class: full-width-table
|
||||
|
||||
* - :class:`Queue`
|
||||
- A FIFO queue.
|
||||
|
@ -98,6 +106,7 @@ Utilities to spawn subprocesses and run shell commands.
|
|||
|
||||
.. list-table::
|
||||
:widths: 50 50
|
||||
:class: full-width-table
|
||||
|
||||
* - ``await`` :func:`create_subprocess_exec`
|
||||
- Create a subprocess.
|
||||
|
@ -121,6 +130,7 @@ High-level APIs to work with network IO.
|
|||
|
||||
.. list-table::
|
||||
:widths: 50 50
|
||||
:class: full-width-table
|
||||
|
||||
* - ``await`` :func:`open_connection`
|
||||
- Establish a TCP connection.
|
||||
|
@ -156,6 +166,7 @@ Threading-like synchronization primitives that can be used in Tasks.
|
|||
|
||||
.. list-table::
|
||||
:widths: 50 50
|
||||
:class: full-width-table
|
||||
|
||||
* - :class:`Lock`
|
||||
- A mutex lock.
|
||||
|
@ -186,6 +197,7 @@ Exceptions
|
|||
|
||||
.. list-table::
|
||||
:widths: 50 50
|
||||
:class: full-width-table
|
||||
|
||||
|
||||
* - :exc:`asyncio.TimeoutError`
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue