Call Java from MATLAB - MATLAB & Simulink (original) (raw)

You can access existing Java classes to use in the MATLAB workspace. For example, use built-in class packages, such asjava.util, which are included in the Java language. See your Java language documentation for descriptions of these packages. You also can access classes defined in individual .class files, packages, or Java Archive (JAR) files, including classes you develop.

You can run MATLAB with your system version of the Java Runtime Environment (JRE™). For version information, see Versions of OpenJDK Compatible with MATLAB by Release. To set the JRE path in MATLAB, call jenv. To set the path from the operating system prompt, call matlab_jenv.

If instead you want to call MATLAB functions from Java applications, see Call MATLAB from Java.