public class ChunkedInputStream extends InputEntityStream
InputStream
to wrap a source InputStream
that has been
chunked. See section 3.6.1 of HTTP Protocol for more information on chunked
encoding.Constructor and Description |
---|
ChunkedInputStream(Notifiable notifiable,
java.io.InputStream inboundStream)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Closes this input stream but do not close the underlying stream.
|
protected void |
onEndReached()
To be called when the end of the stream is reached.
|
int |
read() |
int |
read(byte[] b,
int off,
int len) |
getInboundStream, onError
public ChunkedInputStream(Notifiable notifiable, java.io.InputStream inboundStream)
notifiable
- The notifiable connection.inboundStream
- The inbound stream.public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.InputStream
java.io.IOException
protected void onEndReached()
InputEntityStream
Connection.setInboundBusy(boolean)
) .onEndReached
in class InputEntityStream
public int read() throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
public int read(byte[] b, int off, int len) throws java.io.IOException
read
in class java.io.InputStream
java.io.IOException
Copyright © 2005-2012. All Rights Reserved.