> Can you explain a bit how things will be different in the javax.scripti=
ng
> world for Beanshell?
I'm not sure exactly what you mean. But...
javax.script is just a scripting language neutral API for running scripts
from Java. It is exactly the same sort of thing as BSF. If you use
javax.script in your app then presumably you won't be tied to one
particular scripting langauge, but will be able to use any language that
has an adapter.
The javax.script API is a bit different than the BeanShell Interpreter
API, but it does allow you to get at all of the important features.
The main enhancement that was not there in BeanShell (but now is) is the
ability to expose the application environment as a Map interface and have
it mapped directly into the BeanShell namespace. You can even make your
own hierarchies of namespaces (in javax.script they are called Bindings)
and get the normal inheritence, etc.
Aside from that nothing will really change. And you can always use the
BeanShell Interpreter API directly if you want to. Ultimately the packag=
e
name may change with the JSR... but we can all talk about that.
Pat
|