Class FileSystemNatives


public final class FileSystemNatives extends Object
This class provides utility methods for calling some native methods related to filesystems.
  • Method Details

    • init

      public static void init()
    • allocatedSizeInBytes

      public static OptionalLong allocatedSizeInBytes(Path path)
      Returns the number of allocated bytes on disk for a given file.
      path - the path to the file
      an OptionalLong that contains the number of allocated bytes on disk for the file. The optional is empty is the allocated size of the file failed be retrieved using native methods