Table of Contents

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

Control a task's behavior

This interface is made available only to ITaskSwitch objects via their nextAction() method, so you don't need to know about this unless you're writing a new kind of event source or task switch. Even then, 90% of the time the YIELD() method is the only one you'll need. The rest should be considered "internal" methods that can break things if you don't know precisely what you're doing and why.

Base Classes   
protocols.Interface
Methods   
CALL
CATCH
RETURN
THROW
YIELD
  CALL 
CALL ( iterator )

Cause task to execute iterator next

  CATCH 
CATCH ()

Don't reraise sys.exc_info() until next THROW()

  RETURN 
RETURN ()

Silently abort the currently-running iterator

  THROW 
THROW ()

Reraise sys.exc_info() when current iterator resumes

  YIELD 
YIELD ( value )

Supply value to next resume() call


Table of Contents

This document was automatically generated on Mon Jan 6 01:11:04 2025 by HappyDoc version 2.1