R
Robert Klemme
I think this maps quite good to the actor model in Io
(www.iolanguage.com).
In Io you call a method like:
obj methodname(args)
and if you call it like:
obj @methodname(args)
it returns you a Future object.
You then test the future object and in case you retriev the value:
future_object isReady
future_object value print
Otherwise you can avoid to handle the future object like this:
obj @@methodname(args) #returns nil
It is an interesting model, and imho seem very OO, simple and
powerful.
To me this approach looks a bit complicate. Normally if you would work
completely event base you would just get an event back with the result.
Otherwise you could use synchronous calls anyway.
Now if I just was good enough to implement Object#async_send() ...
Lemmesee...
.... there is a draft attached.
Regards
robert