Table of Contents

Module: event_threads ./src/peak/events/event_threads.py
Imported modules   
from __future__ import generators
from interfaces import *
from peak.core import protocols, adapt, NOT_GIVEN
from peak.util.advice import advice
from sources import Condition, Value, AnyOf, Observable
from sys import exc_info, _getframe
import time
import traceback
from types import GeneratorType
Functions   
resume
  resume 
resume ()

Call this after every yield in a task

This function returns the event that caused the task to resume, or reraises any exceptions thrown by a nested generator in the task. It should be called after every yield statement in a task, if the statement yields a generator or an ITaskSwitch or IEventSource. (If the statement simply yields a value to its calling generator, it need not be followed by an events.resume() call.)

Note that you should still call this function even if you don't need its return value. Otherwise, errors from other generators will be silently lost.

Exceptions   
t, v, tb
Classes   

Interrupt

Interrupt a task with an error if specified event occurs

ProcedureAsTaskSwitch

Scheduler

Time-based event sources; see events.IScheduler for interface

Task

Thread-like "task" that pauses and resumes in response to events

TaskState

Tracks the state of a task; see events.ITaskState for details

_STask

events.Task' that handles errors better, by relying on a scheduler

_Sleeper

taskFactory

Wrap a generator function to return a new Task each time it's called


Table of Contents

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