Thanks for all the responses.

I hadn't really looked into the ASyncToken until now. However, for me it
seems that using the ASyncToken would be limited to the implementation of
the, for example, save(XML, Function, Function) method.

The calling code doesn't need to know about it. In my opinion this is neater
than something like:

var asyncToken:ASyncToken = save(xml);
asyncToken.addResponder(...

Also, I don't like adding responders after the call has been made. I know it
works, but still...

Maybe I should start a new topic for this next question, but...

...in my implementation, I create a new HTTPService for each call. Any ideas
how (in)efficient this is?  As you can imagine, it keeps the implementation
much simpler. No need for the ASyncToken. Just add new listeners each time a
call is made. Everything is garbage collected..... Oh, hang on, what keeps a
reference to the HTTPService?????
-- 
View this message in context: 
http://www.nabble.com/Best-practice-for-calling-asynchronous-functions--tp20930596p20948799.html
Sent from the FlexCoders mailing list archive at Nabble.com.

Reply via email to