On Sun, Jun 19, 2011 at 5:29 AM, jdrewsen <span dir="ltr"><<a href="mailto:jdrewsen@nospam.com">jdrewsen@nospam.com</a>></span> wrote:<div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">


Very nice. A couple of things I believe would help:<br>
1, Get rid of MailMessageData and use curl.onSend() and a delegate that keeps a reference to the message. That way you don't have to use the lower level Curl.set(infile/readfunction) calls as well.</blockquote><div><br>

</div><div>Ah, that makes it much better. </div><div><br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
2, It would be nice if the static sendMail(...) function worked like the Http/Ftp counterparts. They return a Result object that you can change before performing the actual task. That way you can easily set timeouts etc. If there shouldn't be support for async smtp then this is probably not important though. </blockquote>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"> </blockquote></div><br><div>There should be support for async SMTP.</div><div>The problem is this:</div><div>SMTP.sendMailAsync(...).connectTimeout(dur!"seconds"(60)).localPort(25).?</div>

<div><br></div><div>byLine, byChunk, etc don't make much sense there.</div><div><br></div><div>I think it would be better to get rid of the static sendMail function, and write a performAsync method.</div><div>I'm not sure though.</div>

<div>Something like this:</div><div><a href="https://gist.github.com/1034433">https://gist.github.com/1034433</a></div>