mandag, november 19, 2007

Extension: RubyBindings

Extension name:

RubyBindings

Location:

http://www.daimi.au.dk/~abachn/oe/extensions/RubyBindings/

Purpose:

Create a abstract base class for integrating Ruby into OpenEngine. This class should be used as a super class for your more specific extension that wants to execute ruby scripts.

Dependencies:


Implementation details:

We have used standard ruby C API to implement the ruby integration in OpenEngine. This abstract class gives the ability to run scripts og run entire ruby files. Before each run a Pre() method is called and a Post() method os called after the script has run. These can be overwritten in a subclass, but are here given the default behavior of nothing. A default environment is setup before each run. Subclasses have to specify a Init() method when subclassing from this class. This Init method is used to export classes and methods from C++ to ruby.

Ingen kommentarer: