Class MappedBufferCleaner


  • public class MappedBufferCleaner
    extends Object
    Copied/pasted from the Apache Lucene/Solr project.
    • Field Detail

      • UNMAP_SUPPORTED

        public static final boolean UNMAP_SUPPORTED
        true, if this platform supports unmapping mmapped files.
      • UNMAP_NOT_SUPPORTED_REASON

        public static final String UNMAP_NOT_SUPPORTED_REASON
        if UNMAP_SUPPORTED is false, this contains the reason why unmapping is not supported.
    • Constructor Detail

      • MappedBufferCleaner

        public MappedBufferCleaner()
    • Method Detail

      • freeBuffer

        public static void freeBuffer​(ByteBuffer b)
                               throws IOException
        If a cleaner is available, this buffer will be cleaned. Otherwise, this is a no-op.
        Parameters:
        b - buffer to clean; no-op if buffer is null
        Throws:
        IOException