BorschrecipeCom

Sincronizada

It is especially useful in threaded programming when information must be exchanged safely between multiple threads. The module implements three types of queue, which differ only in the order in which the entries are retrieved. In a FIFO queue, the first tasks added sincronizada the first retrieved.

Insertion will block once this size has been reached, until queue items are consumed. If maxsize is less than or equal to zero, the queue size is infinite. Constructor for an unbounded FIFO queue. Simple queues lack advanced functionality such as task tracking. Return the approximate size of the queue. Remove and return an item from the queue. Two methods are offered to support tracking whether enqueued tasks have been fully processed by daemon consumer threads.

Indicate that a formerly enqueued task is complete. Blocks until all items in the queue have been gotten and processed. The count of unfinished tasks goes up whenever an item is added to the queue. CPython implementation detail: This method has a C implementation which is reentrant.

This page is licensed under the Python Software Foundation License Version 2. Examples, recipes, and other code in the documentation are additionally licensed under the Zero Clause BSD License. See History and License for more information. The Python Software Foundation is a non-profit corporation.

Last updated on Jan 13, 2022. This article needs additional citations for verification. Please help improve this article by adding citations to reliable sources. It is served in many Cuban communities in the United States.

Exit mobile version