Via SWIG

Overview

SWIG is the "Simplified Wrapper Generator", and allows a programmer to wrap his C or C++ application's interface so that it can be used from a number of scripting languages.

Emdros implements SWIG interfaces for a number of languages. They include:

  • Ruby
  • Java
  • Python
  • Perl

This means that you can use Emdros from these scripting languages as though you were writing in C++ with almost no performance overhead. The libraries are linked in through dynamic library loading.

Granted, Java is not a scripting language, but is mentioned as such here for simplicity of presentation.

Note: currently, only Python-bindings and Java-bindings are available on Windows. All are available on Linux. It is unknown whether any will work on Solaris.

Benefits

Benefits include:

  • Having the simplicity and rapid prototyping of scripting languages.
  • Losing none of the power of direct access to the Emdros class hierarchy.
  • Not having to parse the output from MQL, instead directly accessing the CMQLResult object. This reduces performance overhead.

Drawbacks

Drawbacks include:

  • Slightly slower performance than with pure C++.

Previous:Via C++
Up:Ways of calling Emdros
Next:Via mql(1) as a command