The functionality is provided for Python by a library called PyParse. Probably the library can be integrated using Jython.
Simplest way to create a simple parse in Java
Question
I know about CUP or javaCC or some other parser generators,
but I want to add the ability to understand a simple language to my project, without the need to configure a complex tool as CUP.
The language is something a little too complicated to be parsed with regular expressions, since I want to use operators:
|| && ( ) [ ]
Solution 2
OTHER TIPS
The JRE comes with a javascript engine embedded. See http://docs.oracle.com/javase/7/docs/api/javax/script/ScriptEngine.html
Also there is tutorial here -> http://docs.oracle.com/javase/7/docs/technotes/guides/scripting/programmer_guide/
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow