Package org.atmosphere.util
Class ChunkConcatReaderPool
java.lang.Object
org.atmosphere.util.ChunkConcatReaderPool
Creates a signle reader instance from a sequence of readers.
- Author:
- elakito
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidReturn a reader if the reader specified by the key has not been previously created.Returns the specified reader.longvoidsetTimeout(long timeout)
-
Constructor Details
-
ChunkConcatReaderPool
public ChunkConcatReaderPool()
-
-
Method Details
-
addChunk
Return a reader if the reader specified by the key has not been previously created. If the reader has been created, the content is added to that reader and returns null.- Parameters:
key-chunk-continued-- Throws:
IllegalArgumentException
-
getReader
Returns the specified reader. If the reader is absent, returns null. If create is set to true, a new reader is created.- Parameters:
key-create-- Returns:
-
getTimeout
public long getTimeout() -
setTimeout
public void setTimeout(long timeout)
-