Expand description
Core runtime support for inline_java.
This crate is an implementation detail of inline_java_macros. End users
should depend on inline_java instead of this crate directly.
Public items:
JavaError— error type returned byrun_javaand by thejava!/java_fn!macros at program runtime.run_java— compile (if needed) and run a generated Java class.expand_java_args— shell-expand an option string into individual args.cache_dir— compute the deterministic temp-dir path for a Java class.detect_java_version— probejavac -versionand return the major version.
Enums§
- Java
Error - All errors that
java!andjava_fn!can return at runtime (and thatct_java!maps tocompile_error!diagnostics at build time).
Functions§
- base_
cache_ dir - Resolve the root directory used to cache compiled
.classfiles. - cache_
dir - Compute the deterministic cache-dir path used to store compiled
.classfiles. - detect_
java_ version - Detect the installed Java major version by running
javac -version. - expand_
java_ args - Shell-expand
raw(expanding env vars and~), then split into individual arguments (respecting quotes). Returns an empty vec ifrawis empty. - run_
java - Compile (if needed) and run a generated Java class, returning raw stdout bytes.