org.geotools.data.shapefile
Class WritableByteChannelDecorator
java.lang.Object
org.geotools.data.shapefile.WritableByteChannelDecorator
- All Implemented Interfaces:
- java.io.Closeable, java.nio.channels.Channel, java.nio.channels.WritableByteChannel
public class WritableByteChannelDecorator
- extends java.lang.Object
- implements java.nio.channels.WritableByteChannel
A WritableByteChannel that delegates all calls to the underlying
WritableByteChannel but for close()
it also calls
ShapefileFiles.unlock method to release the lock on the URL.
- Author:
- jesse
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WritableByteChannelDecorator
public WritableByteChannelDecorator(java.nio.channels.WritableByteChannel newChannel,
ShpFiles shapefileFiles,
java.net.URL url,
FileWriter requestor)
write
public int write(java.nio.ByteBuffer src)
throws java.io.IOException
- Specified by:
write
in interface java.nio.channels.WritableByteChannel
- Throws:
java.io.IOException
close
public void close()
throws java.io.IOException
- Specified by:
close
in interface java.io.Closeable
- Specified by:
close
in interface java.nio.channels.Channel
- Throws:
java.io.IOException
isOpen
public boolean isOpen()
- Specified by:
isOpen
in interface java.nio.channels.Channel
Copyright © 1996-2010 Geotools. All Rights Reserved.