public static class TemporaryBuffer.Heap extends TemporaryBuffer
If the in-memory limit is reached an IOException is thrown, rather than attempting to spool to local disk.
TemporaryBuffer.Heap, TemporaryBuffer.LocalFile
DEFAULT_IN_CORE_LIMIT
Constructor and Description |
---|
TemporaryBuffer.Heap(int limit)
Create a new heap buffer with a maximum storage limit.
|
Modifier and Type | Method and Description |
---|---|
protected java.io.OutputStream |
overflow()
Open the overflow output stream, so the remaining output can be stored.
|
close, copy, destroy, doFlush, length, openInputStream, reset, toByteArray, write, write, writeTo
public TemporaryBuffer.Heap(int limit)
limit
- maximum number of bytes that can be stored in this buffer.
Storing beyond this many will cause an IOException to be
thrown during write.protected java.io.OutputStream overflow() throws java.io.IOException
TemporaryBuffer
overflow
in class TemporaryBuffer
java.io.IOException
- the buffer cannot create the overflow stream.Copyright © 2012. All Rights Reserved.