[][src]Function java_locator::locate_java_home

pub fn locate_java_home() -> Result<String>

Returns the Java home path.

If JAVA_HOME env var is defined, the function returns it without any checks whether the var points to a valid directory or not.

If JAVA_HOME is not defined, the function tries to locate it using the java executable.