public class MimeBoundaryInputStream extends LineReaderInputStream
isLastPart()
can be used to determine if a final boundary has been seen or not.in| Constructor and Description |
|---|
MimeBoundaryInputStream(BufferedLineReaderInputStream inbuffer,
String boundary)
Creates a new MimeBoundaryInputStream.
|
MimeBoundaryInputStream(BufferedLineReaderInputStream inbuffer,
String boundary,
boolean strict)
Creates a new MimeBoundaryInputStream.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes the underlying stream.
|
boolean |
eof() |
boolean |
isEmptyStream() |
boolean |
isFullyConsumed() |
boolean |
isLastPart() |
boolean |
markSupported() |
int |
read() |
int |
read(byte[] b,
int off,
int len) |
boolean |
readAllowed() |
int |
readLine(ByteArrayBuffer dst)
Reads one line of text into the given
ByteArrayBuffer. |
String |
toString() |
boolean |
unread(ByteArrayBuffer buf)
Tries to unread the last read line.
|
public MimeBoundaryInputStream(BufferedLineReaderInputStream inbuffer, String boundary, boolean strict) throws IOException
inbuffer - The underlying stream.boundary - Boundary string (not including leading hyphens).IllegalArgumentException - when boundary is too longIOExceptionpublic MimeBoundaryInputStream(BufferedLineReaderInputStream inbuffer, String boundary) throws IOException
inbuffer - The underlying stream.boundary - Boundary string (not including leading hyphens).IllegalArgumentException - when boundary is too longIOExceptionpublic void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableclose in class FilterInputStreamIOException - on I/O errors.public boolean markSupported()
markSupported in class FilterInputStreamInputStream.markSupported()public boolean readAllowed()
throws IOException
IOExceptionpublic int read()
throws IOException
read in class FilterInputStreamIOExceptionInputStream.read()public int read(byte[] b,
int off,
int len)
throws IOException
read in class FilterInputStreamIOExceptionpublic int readLine(ByteArrayBuffer dst) throws IOException
LineReaderInputStreamByteArrayBuffer.readLine in class LineReaderInputStreamdst - Destination-1 if the end of
the stream has been reached.MaxLineLimitException - if the line exceeds a limit on
the line length imposed by a subclass.IOException - in case of an I/O error.public boolean isEmptyStream()
public boolean isFullyConsumed()
public boolean isLastPart()
public boolean eof()
public boolean unread(ByteArrayBuffer buf)
LineReaderInputStreamunread in class LineReaderInputStreamCopyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.