BeanShell is a small, free, embeddable Java source interpreter with object scripting language features, written in Java. It runs in the Java Runtime Environment (JRE), dynamically executes standard Java syntax and extends it with common scripting conveniences such as loose types, commands, and method closures, like those in Perl and JavaScript.
via Wikipedia infobox
NOTICE: Pending new release The only recommended version is a manual build of the master branch. Support for legacy releases reached end-of-life; only issues and pull requests against master will be accepted. The next release will be BeanShell 3.0, as the development roadmap outlines. It was decided that the next release would be a production-ready major version with all outstanding issues resolved to encourage community involvement and testing. Most of the outstanding issues were imported from Sourceforge, where they were reported many years ago and are now orphaned without owners. The majority has already been resolved on master. An earnest call goes out for assistance in processing these issues to verify whether they are still valid, reproducible, or already resolved. Items identified as out of scope for 3.0 are scheduled for the next release. StrictJava compliance, unit tests, and outstanding issues Updated documentation. The discussions double as future documentation. Introduction BeanShell is a small, free, embeddable Java source interpreter written in Java with object scripting language features. BeanShell executes standard Java syntax dynamically and extends it with common scripting conveniences such as loose types, commands, and method closures like those in Perl and JavaScript. You can use BeanShell interactively for Java experimentation and debugging as well as to extend your applications in new ways. Scripting Java lends itself to various applications, including rapid prototyping, user scripting extension, rules engines, configuration, testing, dynamic deployment, embedded systems, and Java education. BeanShell is small and embeddable, so you can call BeanShell from your Java applications to execute Java code dynamically at run-time or to provide extensibility in your applications. Alternatively, you can use standalone BeanShell scripts to work with Java objects and APIs to manipulate Java applications dynamically. Since BeanShell is written in Java and runs in the same VM as your application, you can freely pass references to "live" objects into scripts and return them as results. Starting with version 2.0b5, BeanShell is licensed under the Apache License, version 2.0. See LICENSE for details and the NOTICE file for required attributions. Source code The development branch is the master, and it is currently recommended that you use that version. To build, pull the project, and run the maven command. BeanShell requires at least JDK 8 but will also work with LTS versions; Java 11, Java 17, and Java 21. Latest release: not supported (use the recommended development snapshot) BeanShell 2.1.1 - bsh-2.1.1-src.zip Beanshell 3.0.0 currently only has a SNAPSHOT release published to Sonatype. To use Beanshell with Maven, add this to your pom.xml : You can also download the bsh.jar binary from the releases page or the link below: bsh-2.1.1.jar or the supplied helper scripts bsh or bsh.bat , available under the scripts folder. You are encouraged to raise a Github Pull Request with any suggested improvements and fixes! You can also raise an issue for any questions or bugs. Remember, your stack trace might be particularly useful for others! Please note only issues and pull requests made against the master branch will be considered. For full documentation, see the BeanShell wiki and the FAQ for frequently asked questions. Summary of features Dynamic execution of the entire Java syntax, Java code fragments, loosely typed Java, and additional scripting conveniences. Transparent access to all Java objects and APIs. Runs in four modes: Command Line, Console, Applet, and Remote Session Server. Works in security-constrained environments without a classloader or bytecode generation for most features. The interpreter is small, ~400K jar file. Pure Java. It's Free!!! Java evaluation features Dynamically evaluate full Java source classes, isolated Java methods, statements, and expressions. Scripting features Optionally
~4 min read
BeanShell is a small, free, embeddable Java source interpreter with object scripting language features, written in Java. It runs in the Java Runtime Environment (JRE), dynamically executes standard Java syntax and extends it with common scripting conveniences such as loose types, commands, and method closures, like those in Perl and JavaScript.
== Features == While BeanShell allows its users to define functions that can be called from within a script, its underpinning philosophy has been to not pollute its syntax with too many extensions and "syntactic sugar", thereby ensuring that code written for a Java compiler can usually be executed interpretively by BeanShell without any changes and, almost just as much, vice versa. This makes BeanShell a popular testing and debugging tool for the Java virtual machine (JVM) platform.
Excerpt from the source-code README · 14,081 chars · not written by Vinony
via Wikidata · CC0
Discovered by embedding cosine similarity (sentence-transformers MiniLM, 384-dim).