MCPcopy Create free account
hub / github.com/RT-Thread/env-windows / reset

Method reset

tools/python-3.11.9-amd64/Lib/asyncio/locks.py:547–560  ·  view source on GitHub ↗

Reset the barrier to the initial state. Any tasks currently waiting will get the BrokenBarrier exception raised.

(self)

Source from the content-addressed store, hash-verified

545 self._cond.notify_all()
546
547 async def reset(self):
548 """Reset the barrier to the initial state.
549
550 Any tasks currently waiting will get the BrokenBarrier exception
551 raised.
552 """
553 async with self._cond:
554 if self._count > 0:
555 if self._state is not _BarrierState.RESETTING:
556 #reset the barrier, waking up tasks
557 self._state = _BarrierState.RESETTING
558 else:
559 self._state = _BarrierState.FILLING
560 self._cond.notify_all()
561
562 async def abort(self):
563 """Place the barrier into a 'broken' state.

Callers 3

startFunction · 0.45
mainFunction · 0.45
mainFunction · 0.45

Calls 1

notify_allMethod · 0.45

Tested by

no test coverage detected