something like REXX interpret in Java

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

something like REXX interpret in Java

Horst
Our list generator's GUI is written in Java and runs a REXX skript to get the data from database.
The skript interprets column formatting, calculates columns and uses conditions etc.
Our customers are used to define own columns in REXX syntax. Therefore we created a lot of macros like Excel does    =IF(A2=15, "OK", "Not OK")     IF() is a rexx procedure.
There are macros to get data from database too, that can be used in a very senseful way.
Meanwhile we defined more than 3000 columns in a lot of entities and made them available for the list generator.

We often have the same requirement to run skript code in non REXX applications (Java, C++, C#).
In the moment we are developing a digital signage app in Java.
We need i.e. generic conditions, to decide which playlist has to be started, like

     condition                                                                 playlist ID
     (CustomerSex="male" & CustomerAge>60) | .....        "footcare"

To develop dialogs for entering the conditions cost a lot of time and will never be so flexible like a condition in REXX syntax.
The Java app should fill the variables (CustomerSex,...), run the condition text (like interpret) and gets a returncode back (0/1).  
Does anyone have an idea how to do that?