Hi folks!

I'm new to SWIG and have been perusing the docs to figure out how to do callbacks in Ruby. Basically, I'd like to be able to make a call in Ruby to a C++ function passing in a Ruby callback method that the C++ function can then execute at a later point when the operation is done.

As far as I can tell, this isn't as straightforward as I was hoping for. I know I can use directors to allow my native code to call in to Ruby, but that's more for general cases where, say, an event happened in native code and I want to propagate that event to my Ruby code.

In this particular case, I'd like to make a call in Ruby, which fires off an asynchronous operation in native code, and then I'd like to be called back (in Ruby) when that operation has finished.

I was hoping somebody could point me in the right direction.

Many thanks,
Soren