org.geotools.resources
Class NIOUtilities

java.lang.Object
  extended byorg.geotools.resources.NIOUtilities

public class NIOUtilities
extends java.lang.Object

Utility class for managing memory mapped buffers.

Version:
$Id: NIOUtilities.java 10796 2005-01-28 19:09:18Z dzwiers $
Author:
Andres Aimes

Constructor Summary
protected NIOUtilities()
          Do not allows instantiation of this class.
 
Method Summary
static boolean clean(java.nio.ByteBuffer buffer)
          Really closes a MappedByteBuffer without the need to wait for garbage collection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NIOUtilities

protected NIOUtilities()
Do not allows instantiation of this class.

Task:
TODO: This constructor will become private when NIOBufferUtils will have been removed.
Method Detail

clean

public static boolean clean(java.nio.ByteBuffer buffer)
Really closes a MappedByteBuffer without the need to wait for garbage collection. Any problems with closing a buffer on Windows (the problem child in this case) will be logged as SEVERE to the logger of the package name. To force logging of errors, set the System property "org.geotools.io.debugBuffer" to "true".

Parameters:
buffer - The buffer to close.
Returns:
true if the operation was successful, false otherwise.
See Also:
MappedByteBuffer


Copyright © GeoTools. All Rights Reserved.