Class FstatUtil

java.lang.Object
oshi.util.platform.unix.openbsd.FstatUtil

@ThreadSafe public final class FstatUtil extends Object
Reads from fstat.
  • Method Details

    • getCwd

      public static String getCwd(int pid)
      Gets current working directory info (using ps actually).
      Parameters:
      pid - a process ID
      Returns:
      the current working directory for that process.
    • getOpenFiles

      public static long getOpenFiles(int pid)
      Gets open number of files.
      Parameters:
      pid - The process ID
      Returns:
      the number of open files.