Scripting in Java 6.0
by Krishna Srinivasan
In this article i will write a small program using Scripting feature in Java 6.0, a new feature introduced in Java 6.0 mustang. This is cool and more useful when we are working with the scripting languages. I am not going to explain in depth, will explain with very small example. In my next article i will write about the advanced features in script programming in java. Follow the steps to run your first script program in Java 6.0 :
Java Scripting in Java 6.0 (Mustang) - Article
Spring Resources and Articles
Struts Tutorials and Articles
This method looks just like normal invocation of Rhino engine.
What are the differences?
|I am relatively new to the concept of scripting like your article describes. After reading it I wonder why in the world people would want to do that as opposed to just sticking with plain old Java?|
One example of scripting with a VM that I like is as a replacement for large XML descriptors. A lot of XML we write is basically a type of interpreted language, we might as well go all the way. Consider for example that .bashrc is configuration, in the format of a script. Instead of writing a parser, and a file format, you just use bash to configure your bash shell.
Is there even one? Youtube is written in Phyton for example.