Package twisted :: Package flow :: Module base :: Class Cooperate

[frames | no frames]

## Class Cooperate

    Instruction --+
                  |
          CallLater --+
                      |
                     Cooperate

    Requests that processing be paused so other tasks can resume

    Yield this object when the current chain would block or periodically
    during an intensive processing task.   The flow mechanism uses these
    objects to signal that the current processing chain should be paused
    and resumed later.  This allows other delayed operations to be
    processed, etc.  Usage is quite simple:

           // within some generator wrapped by a Controller
           yield Cooperate(1)  # yield for a second or more

Method Summary
| `__init__(self, timeout)`
| `callLater(self, callable)`

Generated by Epydoc 2.0 on Sat May 15 20:08:23 2004 | http://epydoc.sf.net