gnu.inet.util
Class CRLFInputStream
FilterInputStream
gnu.inet.util.CRLFInputStream
public class CRLFInputStream
extends FilterInputStream
An input stream that filters out CR/LF pairs into LFs.
Version:
- Chris Burdess
static int | CR - The CR octet.
|
static int | LF - The LF octet.
|
protected int | buf - Buffer.
|
protected int | markBuf - Buffer at time of mark.
|
CRLFInputStream(InputStream in) - Constructs a CR/LF input stream connected to the specified input
stream.
|
void | mark(int readlimit) - Marks the current position in this stream.
|
boolean | markSupported() - Indicates whether this stream supports the mark and reset methods.
|
int | read() - Reads the next byte of data from this input stream.
|
int | read(byte[] b) - Reads up to b.length bytes of data from this input stream into
an array of bytes.
|
int | read(byte[] b, int off, int len) - Reads up to len bytes of data from this input stream into an
array of bytes, starting at the specified offset.
|
void | reset() - Repositions this stream to the position at the time the mark method was
called.
|
CR
public static final int CR
The CR octet.
- 13
LF
public static final int LF
The LF octet.
- 10
buf
protected int buf
Buffer.
markBuf
protected int markBuf
Buffer at time of mark.
CRLFInputStream
public CRLFInputStream(InputStream in)
Constructs a CR/LF input stream connected to the specified input
stream.
mark
public void mark(int readlimit)
Marks the current position in this stream.
markSupported
public boolean markSupported()
Indicates whether this stream supports the mark and reset methods.
read
public int read()
throws IOException
Reads the next byte of data from this input stream.
Returns -1 if the end of the stream has been reached.
read
public int read(byte[] b)
throws IOException
Reads up to b.length bytes of data from this input stream into
an array of bytes.
Returns -1 if the end of the stream has been reached.
read
public int read(byte[] b,
int off,
int len)
throws IOException
Reads up to len bytes of data from this input stream into an
array of bytes, starting at the specified offset.
Returns -1 if the end of the stream has been reached.
reset
public void reset()
throws IOException
Repositions this stream to the position at the time the mark method was
called.
© Copyright 2003 The Free Software Foundation,
all rights reserved