Table of Contents

Class: ISemaphore ./src/peak/events/interfaces.py

An event source that allows n tasks to proceed at once

Unlike a conditional or value, a semaphore distributes its events to at most one accepting callback. This ensures that tasks waiting for the semaphore are not awakened if other tasks remove all available tokens first.

Base Classes   
IWritableSource
IConditional
Methods   
put
take
  put 
put ()

Increase the number of runnable tasks by 1

  take 
take ()

Decrease the number of runnable tasks by 1


Table of Contents

This document was automatically generated on Mon Apr 22 01:11:04 2024 by HappyDoc version 2.1