~certify-web-dev/twisted/certify-trunk

« back to all changes in this revision

Viewing changes to doc/howto/defer.html

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2007-01-17 14:52:35 UTC
  • mfrom: (1.1.5 upstream) (2.1.2 etch)
  • Revision ID: james.westby@ubuntu.com-20070117145235-btmig6qfmqfen0om
Tags: 2.5.0-0ubuntu1
New upstream version, compatible with python2.5.

Show diffs side-by-side

added added

removed removed

Lines of Context:
118
118
 
119
119
<span class="py-src-comment"># this series of callbacks and errbacks will print &quot;Result: 12&quot;
120
120
</span><span class="py-src-variable">g</span> = <span class="py-src-variable">Getter</span>()
121
 
<span class="py-src-variable">d</span> = <span class="py-src-variable">g</span>.<span class="py-src-variable">getData</span>(<span class="py-src-number">4</span>)
 
121
<span class="py-src-variable">d</span> = <span class="py-src-variable">g</span>.<span class="py-src-variable">getDummyData</span>(<span class="py-src-number">4</span>)
122
122
<span class="py-src-variable">d</span>.<span class="py-src-variable">addCallback</span>(<span class="py-src-variable">printData</span>)
123
123
<span class="py-src-variable">d</span>.<span class="py-src-variable">addErrback</span>(<span class="py-src-variable">printError</span>)
124
124
 
414
414
  otherDeferred.errback)</code></p></li></ul><h2>See also<a name="auto12"></a></h2><ol><li><a href="gendefer.html">Generating Deferreds</a>, an introduction to
415
415
writing asynchronous functions that return Deferreds.</li></ol><h2>Footnotes</h2><ol><li><a name="footnote-1"><span xmlns="http://www.w3.org/1999/xhtml" class="footnote">Unless of course a later callback starts a fresh error &mdash;
416
416
but as we've already noted, adding callbacks to a Deferred after its used in a
417
 
DeferredList is confusing and usually avoided.</span></a></li></ol></div><p><a href="../howto/index.html">Index</a></p><span class="version">Version: 2.4.0</span></body></html>
 
 
b'\\ No newline at end of file'
 
417
DeferredList is confusing and usually avoided.</span></a></li></ol></div><p><a href="../howto/index.html">Index</a></p><span class="version">Version: 2.5.0</span></body></html>
 
 
b'\\ No newline at end of file'