public abstract class AbstractHigherOrderHandle<L extends Location> extends AbstractDataHandle<L>
DataHandles that operate over other
DataHandles.DataHandle.ByteOrderDEFAULT_BLOCK_SIZE, MAX_SEARCH_SIZE| Constructor and Description |
|---|
AbstractHigherOrderHandle(DataHandle<L> handle) |
| Modifier and Type | Method and Description |
|---|---|
protected abstract void |
cleanup()
Clean up data structures after a handle has been closed in the
close() method. |
void |
close() |
protected void |
ensureOpen() |
boolean |
exists()
Tests whether this handle's location actually exists at the source.
|
Class<L> |
getType()
Gets the type associated with the object.
|
protected DataHandle<L> |
handle() |
boolean |
isReadable()
Gets whether reading from this handle is supported.
|
boolean |
isWritable()
Gets whether writing to this handle is supported.
|
long |
length()
Returns the length of the data in bytes.
|
conversionBuffer, getEncoding, getOrder, setEncoding, setOrderget, setsupportsgetInfo, getPriority, setInfo, setPriority, toStringcontext, getContextclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitavailable, checksum, ensureReadable, ensureWritable, findString, findString, findString, findString, isBigEndian, isLittleEndian, lastModified, offset, read, read, read, readBoolean, readChar, readCString, readDouble, readFloat, readFully, readFully, readInt, readLine, readLong, readShort, readString, readString, readUnsignedByte, readUnsignedShort, readUTF, seek, setLength, setLittleEndian, skip, skipBytes, write, writeBoolean, writeByte, writeBytes, writeChar, writeChars, writeDouble, writeFloat, writeInt, writeLine, writeLong, writeShort, writeUTFget, setgetIdentifier, logcontext, getContext, setContextcompareTo, getPriority, setPrioritygetInfo, setInfogetLocationgetVersionwrite, writepublic AbstractHigherOrderHandle(DataHandle<L> handle)
public boolean isReadable()
DataHandlepublic boolean isWritable()
DataHandlepublic long length()
throws IOException
DataHandleIOExceptionpublic Class<L> getType()
Typedpublic boolean exists()
throws IOException
DataHandleIOException - If something goes wrong with the existence check.public void close()
throws IOException
IOExceptionprotected void ensureOpen()
throws IOException
IOExceptionprotected abstract void cleanup()
throws IOException
close() method.IOExceptionprotected DataHandle<L> handle()
DataHandle wrapped by this
AbstractHigherOrderHandleCopyright © 2015–2022 SciJava. All rights reserved.