Package com.yahoo.io

Class NativeIO


  • public class NativeIO
    extends Object
    Provides functionality only possible through native C library.
    • Constructor Detail

      • NativeIO

        public NativeIO()
    • Method Detail

      • valid

        public boolean valid()
      • dropPartialFileFromCache

        public void dropPartialFileFromCache​(FileDescriptor fd,
                                             long offset,
                                             long len,
                                             boolean sync)
        Will hint the OS that data read so far will not be accessed again and should hence be dropped from the buffer cache.
        Parameters:
        fd - The file descriptor to drop from buffer cache.
      • dropFileFromCache

        public void dropFileFromCache​(FileDescriptor fd)
        Will hint the OS that this is will not be accessed again and should hence be dropped from the buffer cache.
        Parameters:
        fd - The file descriptor to drop from buffer cache.
      • dropFileFromCache

        public void dropFileFromCache​(File file)
        Will hint the OS that this is will not be accessed again and should hence be dropped from the buffer cache.
        Parameters:
        file - File to drop from buffer cache