public class HttpInputStream
extends java.io.FilterInputStream
LineInput
Constructor and Description |
---|
HttpInputStream(java.io.InputStream in)
Constructor.
|
HttpInputStream(java.io.InputStream in,
int bufferSize)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
destroy() |
int |
getContentLength()
Get the content length.
|
java.io.OutputStream |
getExpectContinues() |
java.io.InputStream |
getFilterStream()
Get Filter InputStream.
|
java.io.InputStream |
getInputStream()
Get the raw stream.
|
HttpFields |
getTrailer() |
boolean |
isChunking()
Get chunking mode
|
int |
read() |
int |
read(byte[] b) |
int |
read(byte[] b,
int off,
int len) |
void |
resetStream()
Reset the stream.
|
void |
setChunking()
Set chunking mode.
|
void |
setContentLength(int len)
Set the content length.
|
void |
setExpectContinues(java.io.OutputStream expectContinues) |
void |
setFilterStream(java.io.InputStream filter)
Set Filter InputStream.
|
long |
skip(long n) |
public HttpInputStream(java.io.InputStream in)
public HttpInputStream(java.io.InputStream in, int bufferSize)
public java.io.OutputStream getExpectContinues()
expectContinues
- The expectContinues to set.public void setExpectContinues(java.io.OutputStream expectContinues)
expectContinues
- The expectContinues to set.public int read() throws java.io.IOException
read
in class java.io.FilterInputStream
java.io.IOException
public int read(byte[] b, int off, int len) throws java.io.IOException
read
in class java.io.FilterInputStream
java.io.IOException
public int read(byte[] b) throws java.io.IOException
read
in class java.io.FilterInputStream
java.io.IOException
public long skip(long n) throws java.io.IOException
skip
in class java.io.FilterInputStream
java.io.IOException
public java.io.InputStream getInputStream()
public java.io.InputStream getFilterStream()
public void setFilterStream(java.io.InputStream filter)
public boolean isChunking()
public void setChunking() throws java.lang.IllegalStateException
java.lang.IllegalStateException
- Checking cannot be set if
a content length has been set.public void resetStream() throws java.lang.IllegalStateException
java.lang.IllegalStateException
- The stream cannot be reset if
there is some unread chunked input or a content length greater
than zero remaining.public void close() throws java.io.IOException
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
close
in class java.io.FilterInputStream
java.io.IOException
public void setContentLength(int len)
len
- length.public int getContentLength()
public HttpFields getTrailer()
public void destroy()
Copyright © 2004 Mortbay Consulting Pty. Ltd. All Rights Reserved.