Package org.h2.util
Class MemoryUnmapper
java.lang.Object
org.h2.util.MemoryUnmapper
Unsafe memory unmapper.
- See Also:
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
unmap
(ByteBuffer buffer) Tries to unmap memory for the specified byte buffer using Java internals in unsafe way ifSysProperties.NIO_CLEANER_HACK
is enabled and access is not denied by a security manager.
-
Field Details
-
ENABLED
private static final boolean ENABLED -
UNSAFE
-
INVOKE_CLEANER
-
-
Constructor Details
-
MemoryUnmapper
private MemoryUnmapper()
-
-
Method Details
-
unmap
Tries to unmap memory for the specified byte buffer using Java internals in unsafe way ifSysProperties.NIO_CLEANER_HACK
is enabled and access is not denied by a security manager.- Parameters:
buffer
- mapped byte buffer- Returns:
- whether operation was successful
-