</p>\r
</dd>\r
<dt class="hdlist1">\r
+<tt>promise.emitSuccess(arg1, arg2, …)</tt> \r
+</dt>\r
+<dd>\r
+<p>\r
+If you created the promise (by doing <tt>new node.Promise()</tt>) then call\r
+<tt>emitSuccess</tt> to emit the <tt>"success"</tt> event with the given arguments.\r
+</p>\r
+<div class="paragraph"><p>(<tt>promise.emit("success", arg1, arg2, …)</tt> should also work, but doesn’t at\r
+the moment due to a bug; use <tt>emitSuccess</tt> instead.)</p></div>\r
+</dd>\r
+<dt class="hdlist1">\r
+<tt>promise.emitError(arg1, arg2, …)</tt> \r
+</dt>\r
+<dd>\r
+<p>\r
+Emits the <tt>"error"</tt> event.\r
+</p>\r
+</dd>\r
+<dt class="hdlist1">\r
<tt>promise.wait()</tt> \r
</dt>\r
<dd>\r
<div id="footer">\r
<div id="footer-text">\r
Version 0.1.10<br />\r
-Last updated 2009-09-13 18:25:27 CEST\r
+Last updated 2009-09-15 15:23:59 CEST\r
</div>\r
</div>\r
</body>\r
+promise.addErrback(listener)+ ::
Adds a listener for the +"error"+ event. Returns the same promise object.
++promise.emitSuccess(arg1, arg2, ...)+ ::
+If you created the promise (by doing +new node.Promise()+) then call
++emitSuccess+ to emit the +"success"+ event with the given arguments.
++
+(+promise.emit("success", arg1, arg2, ...)+ should also work, but doesn't at
+the moment due to a bug; use +emitSuccess+ instead.)
+
++promise.emitError(arg1, arg2, ...)+ ::
+Emits the +"error"+ event.
+
+promise.wait()+ ::
Blocks futher execution until the promise emits a success or error event.
Events setup before the call to +promise.wait()+ was made may still be
.\" Title: node
.\" Author:
.\" Generator: DocBook XSL Stylesheets v1.73.2 <http://docbook.sf.net/>
-.\" Date: 09/13/2009
+.\" Date: 09/15/2009
.\" Manual:
.\" Source:
.\"
-.TH "NODE" "1" "09/13/2009" "" ""
+.TH "NODE" "1" "09/15/2009" "" ""
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
event\. Returns the same promise object\.
.RE
.PP
+promise\.emitSuccess(arg1, arg2, \&...)
+.RS 4
+If you created the promise (by doing
+new node\.Promise()) then call
+emitSuccess
+to emit the
+"success"
+event with the given arguments\.
+.sp
+(promise\.emit("success", arg1, arg2, \&...)
+should also work, but doesn\(cqt at the moment due to a bug; use
+emitSuccess
+instead\.)
+.RE
+.PP
+promise\.emitError(arg1, arg2, \&...)
+.RS 4
+Emits the
+"error"
+event\.
+.RE
+.PP
promise\.wait()
.RS 4
Blocks futher execution until the promise emits a success or error event\. Events setup before the call to