Package Products :: Package ZenUtils :: Module Timeout :: Class TimeoutDeferred |
[hide private]
[frames] | no frames]

# Class TimeoutDeferred

source code

    twisted.internet.defer.Deferred --+
                                      |
                                     TimeoutDeferred

A deferred that fires errback if the result doesn't come back in the given time period

Instance Methods | [hide private]
__init__(self, other, timeout) Wrap the passed deferred and return a new deferred that will timeout | source code
_timeout(self) The wrapped deferred was too slow: fire the errback | source code
_startRunCallbacks(self, result) We have a result, fire callbacks or cancel the timer | source code
Inherited from `twisted.internet.defer.Deferred`: `__repr__`, `__str__`, `addBoth`, `addCallback`, `addCallbacks`, `addErrback`, `callback`, `cancel`, `chainDeferred`, `errback`, `pause`, `unpause` Inherited from `twisted.internet.defer.Deferred` (private): `_continuation`, `_runCallbacks`

Class Variables | [hide private]
| timer = `None`
Inherited from `twisted.internet.defer.Deferred`: `debug` Inherited from `twisted.internet.defer.Deferred` (private): `_debugInfo`

Instance Variables | [hide private]
Inherited from `twisted.internet.defer.Deferred`: `called`, `paused` Inherited from `twisted.internet.defer.Deferred` (private): `_chainedTo`, `_runningCallbacks`, `_suppressAlreadyCalled`

Method Details | [hide private]

### __init__(self, other, timeout) (Constructor) | source code
Wrap the passed deferred and return a new deferred that will timeout Parameters: `other` (a Deferred) - the deferred to wrap `timeout` (floating point number) - time, in seconds, to wait before failing the deferred Overrides: twisted.internet.defer.Deferred.__init__

### _startRunCallbacks(self, result) | source code
We have a result, fire callbacks or cancel the timer Overrides: twisted.internet.defer.Deferred._startRunCallbacks