JavaScript Shell in Rhino JavaScript 1.7R5

Q

How the use the JavaScript Shell provided in Rhino JavaScript 1.7R5? I have Rhino 1.7R5 installed.

✍: FYIcenter

A

The JavaScript Shell is a command line tool provided in Rhino JavaScript 1.7R5 allows you to run enter JavaScript code and get it executed immediately.

Here is how to use the JavaScript Shell, if you have Rhino 1.7R5 installed:

>\fyicenter\jdk-1.8.0\bin\java -jar \fyicenter\rhino1_7R5\js.jar

Rhino 1.7 release 5 2015 01 29

js> Math.PI;
3.141592653589793

js> System.out.println("Hello World!");
js: uncaught JavaScript runtime exception: ReferenceError: "System" is not defined.

js> java.lang.System.out.println("Hello World!");
Hello World!

js> load("Hello.js");
Hello, welcome to FYIcenter.com!

js> <Ctrl-C>
>

 

What Is Rhino JavaScript rhino1_7R3.zip

What Is js.jar in Rhino JavaScript 1.7R5

Download and Review Rhino JavaScript Java Library

⇑⇑ FAQ for Rhino JavaScript Java Library

2017-08-21, 1865🔥, 0💬