The jython Interpreter

The jython interpreter built during installation (see Installing Jython) is run similarly to the python program:

[path]jython {options} [ -j jar | -c command | file | - ] {arguments}

-j jar tells jython that the main script to run is _ _run_ _.py in the .jar file. Options -i, -S, and -v are the same as for python. --help is like python’s -h, and --version is like python’s --V. Instead of environment variables, jython uses a text file named registry in the installation directory to record properties with structured names. Property python.path, for example, is the Jython equivalent of Python’s environment variable PYTHONPATH. You can also set properties with jython command-line options in the form -D name=value.

Get Python in a Nutshell, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.