To all --
I have written an experimental JSR223 script engine for NetRexx. The binary jar and some minimal documentation are posted on my scripting page: http://kermitkiser.com/NetRexx/Script Source is not far enough along to post and there are no performance optimizations yet so usefulness is limited. I am indefinitely suspending development on the NetRexx JSR223 engine at this time. The reasons are as follows: 1) When I started to test the engine, I searched the internet for environments which could accept a JSR223 engine. I could not find anything useful. There is some documentation with a complex procedure which might allow a JSR223 script engine to work in Open Office and there is a similar complex procedure documented which might allow it to work with Eclipse, but there is pretty much nothing which can accept a vanilla JSR223 engine as defined by the Java specification. Even the jEdit environment that I use for NetRexx development requires a custom plugin for each language in order to properly handle JSR223 engines. This leads me to suspect that there really is not much demand for this type of scripting software at this time. 2) Possibly because of the above reason, I don't think there is anyone prepared and available to test this software in any environment presently. Please correct me if I am wrong. 3) JSR223 is a very poorly designed interface for scripting languages. For example: All scripts are passed to script engines as a string in memory or as a reader of some unknown input stream. The current NetRexx interpreter only accepts '*.nrx" file names for scripts and reads them from the files directly. To make things worse, the JSR223 spec defines a file name context variable which can be used to pass a file name to an engine but provides no rules about who sets the value or when it should be set. Consequently, while the jrunscript test program for JSR223 engines provided in the JDK sets the file name parameter when passing a file reader, the only other JSR223 test environment I currently have (jEdit's ScriptEnginePlugin) passes filenames in a completely different context variable. While I currently bypass the filename problems by creating script file copies in the user's profile area, a proper solution to allow processing scripts from memory will have to wait for open source NetRexx and some enhancements there. Another example: JSR223 passes "readers" and "writers" for scripts to use for console type input/output while all Java programs, including the NetRexx interpreter and it's scripts use the input/output streams found in System.in/out for console IO. Another reason to wait for open source NetRexx and some option enhancements there! 4) I now have a "Droid". I have succeeded in compiling simple NetRexx programs for the Android platform and running them on my Droid phone. This is a relatively new environment where the competitive advantage of NetRexx coding could be significant and it seems about to explode. Therefore I am focusing my current efforts on building a NetRexx development environment for Android programming. If someone makes a compelling case otherwise or things change, I will reconsider this decision. Perhaps the ASE (Android Scripting Environment) will open up and support JSR223 - running NetRexx scripts on a cell phone would be very interesting! I will cross post this to RexxLA in case there is some JSR223 interest there. -- Kermit |
Free forum by Nabble | Edit this page |