java_runtimes::detector

Function gather_java

Source
pub fn gather_java(
    runtimes: &mut Vec<JavaRuntime>,
    path: &Path,
    max_depth: usize,
) -> usize
Expand description

Detects available Java runtimes within the specified path and appends them to the given vector.

§Parameters

  • runtimes: Vector to contain detected Java runtimes.
  • path: The path to search for Java runtimes.
  • max_depth: Maximum depth to search for Java runtimes (see WalkDir::max_depth).

§Returns

The number of new Java runtimes added to the vector.