You can use OOEU as an embeddable scripting engine for your applications (whether an OOEU or a normal Euphoria application). First, you'll need to include eu.e (instead of eu.ex) in your application. Then use embed_routine() to allow scripts to call routines inside of your application, and use illegal_builtin() to restrict scripts from calling certain builtin routines. Then you can use do_eval() to run scripts.
Alternatively, eu.e can be compiled into a dynamic library (see the libooeu.dll/so files provided in the binary distribution) and use it that way in order to speed up your scripts' execution. Instead of including eu.e, simply include libooeu.e, and use it exactly the same way that you would use eu.e.
If your scripting uses the debugger, you should call this routine before your program exits in order to cleanly shut down the debugger. Failure to do so could cause a machine exception to occur when your application closes.
Resets the current scripting environment. This allows an application to recycle scripting environments and avoid leaking resources by simply adding new scripting environments as they are needed.
This is the function that will run embedded OOEU code. The code should be passed as a sequence of text with '\n's breaking up lines. If a routine is passed, the entire routine should be passed at once, or an error will result. If any errors were encountered, the return value will be zero. If there were no errors, the return value will be 1.
This function is used to allow scripts to call routines in your application. The parameter values should be as follows:
Returns the handle for the currently active scripting environment.
This function will return a sequence containing information about the error encountered.
This procedure can be used to remove the ability of evaluated code from using builtin routines. Pass the name of the builtin routine, or a sequence of builtin routines, and if any code calls that routine, an illegal call error will occur. See the predefined lists supplied in illegal.e. For a full list of builtins that can be declared illegal, see keylist.e (with the addition of the question mark: "?").
Creates a new scripting environment. The return value is the handle of the environment. This environment will be completely separate from other scripting environments. Note that the initial environment is automatically set up for you.
Saves the current environment and switches to the specified environment.