Package com.aoindustries.io.buffer
Class TempFileResult
- java.lang.Object
-
- com.aoindustries.io.buffer.TempFileResult
-
- All Implemented Interfaces:
BufferResult,Writable
public class TempFileResult extends Object implements BufferResult
This class is not thread safe. TODO: Performance: When reading blocks, align to block boundary instead of remaining offset by start / writeStart.- Author:
- AO Industries, Inc.
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedTempFileResult(TempFile tempFile, long start, long end)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longgetLength()booleanisFastToString()StringtoString()BufferResulttrim()Trims the contents of this result, as per rules ofStrings.isWhitespace(int), returning the instance that represents this result trimmed.voidwriteTo(Encoder encoder, Writer out)voidwriteTo(Encoder encoder, Writer out, long off, long len)voidwriteTo(Writer out)voidwriteTo(Writer out, long off, long len)
-
-
-
Constructor Detail
-
TempFileResult
protected TempFileResult(TempFile tempFile, long start, long end)
-
-
Method Detail
-
isFastToString
public boolean isFastToString()
- Specified by:
isFastToStringin interfaceWritable
-
toString
public String toString()
-
writeTo
public void writeTo(Writer out) throws IOException
- Specified by:
writeToin interfaceWritable- Throws:
IOException
-
writeTo
public void writeTo(Writer out, long off, long len) throws IOException
- Specified by:
writeToin interfaceWritable- Throws:
IOException
-
writeTo
public void writeTo(Encoder encoder, Writer out) throws IOException
- Specified by:
writeToin interfaceWritable- Throws:
IOException
-
writeTo
public void writeTo(Encoder encoder, Writer out, long off, long len) throws IOException
- Specified by:
writeToin interfaceWritable- Throws:
IOException
-
trim
public BufferResult trim() throws IOException
Description copied from interface:BufferResultTrims the contents of this result, as per rules ofStrings.isWhitespace(int), returning the instance that represents this result trimmed.- Specified by:
trimin interfaceBufferResult- Specified by:
trimin interfaceWritable- Throws:
IOException
-
-