public abstract class ProcessableDetectorStream extends AbstractDetectorStream
DetectorStream specific for this
implementation.ProcessableDetectorInputStream,
ProcessableDetectorInputStream| Modifier and Type | Field and Description |
|---|---|
private ByteArrayPool |
byteArrayPool |
private DetectorStreamBufferImpl |
firstBuffer
The first buffer of the chain.
|
| Constructor and Description |
|---|
ProcessableDetectorStream(Map<String,Object> mutableMetadata,
ByteArrayPool byteArrayPool)
The constructor.
|
| Modifier and Type | Method and Description |
|---|---|
protected ByteArrayPool |
getByteArrayPool()
This method gets a pool used to manage byte-arrays.
|
void |
initialize(AbstractDetectorStreamProvider provider,
DetectorStreamProcessor lastProcessor)
This method initializes this class.
|
void |
processInternal(ByteArray buffer,
boolean eos) |
getMetadata, getMutableMetadata, isDone, setDoneprivate final ByteArrayPool byteArrayPool
private DetectorStreamBufferImpl firstBuffer
public ProcessableDetectorStream(Map<String,Object> mutableMetadata, ByteArrayPool byteArrayPool)
initialize(AbstractDetectorStreamProvider, DetectorStreamProcessor) after super
-call in subclass-constructor.mutableMetadata - is the initial mutable metadata.byteArrayPool - is used to pool byte[]-buffers.public void initialize(AbstractDetectorStreamProvider provider, DetectorStreamProcessor lastProcessor)
provider - is the DetectorStreamProvider creating this instance.lastProcessor - is the last DetectorStreamProcessor of the chain (the data-receiver).public void processInternal(ByteArray buffer, boolean eos) throws IOException
buffer - is the next part of the streamed data.eos - - true if the end of the stream has been reached and the given buffer has to beIOException - in case of an Input/Output error. Should only be used internally.DetectorStreamProcessor.process(net.sf.mmm.util.io.api.spi.DetectorStreamBuffer, Map, boolean)protected ByteArrayPool getByteArrayPool()
ByteArrayPool instance.Copyright © 2001–2016 mmm-Team. All rights reserved.