To Call into Java from Spotfire Enterprise Runtime for R
terrJava and TERR work with Java in the same process.
When the terrJava package is loaded in
TERR,
a Java engine starts in the same process, if one is not already running. Using
the
.JavaMethod
function, you can call any static Java
method loaded in the Java engine, which can then run any Java code including
Java UI operations (such as creating windows). You can use the
.JavaAttachClassPath
function to add new Java code at
runtime, which you can then call via .JavaMethod
. The
.JavaMethod
and
.JavaAttachClassPath
functions are both documented in
the help pages for the terrJava package.
- To Load the terrJava Package
Prepare your system before you load the terrJava package. After your system is prepared, you can load the package by callinglibrary()
. - Other Useful Environment Variables
You can set other environment variables to affect the process of loading terrJava. After terrJava has been loaded, setting these variables does not affect it.
- To Load the terrJava Package
Prepare your system before you load the terrJava package. After your system is prepared, you can load the package by callinglibrary()
. - Other Useful Environment Variables
You can set other environment variables to affect the process of loading terrJava. After terrJava has been loaded, setting these variables does not affect it.
Parent topic: Using TERR, the terrJava Package, and Java