gnu.mail.util
Class RFC2822OutputStream
FilterOutputStream
gnu.mail.util.RFC2822OutputStream
public class RFC2822OutputStream
extends FilterOutputStream
An output stream that ensures that lines of characters in the body are
limited to 998 octets(excluding CRLF).
This is required by RFC 2822, section 2.3.
static int | CR - The CR octet.
|
static int | LF - The LF octet.
|
protected int | count - The number of bytes in the line.
|
RFC2822OutputStream(OutputStream out) - Constructs an RFC2822 output stream
connected to the specified output stream.
|
void | write(byte[] b) - Writes a byte array to the underlying stream.
|
void | write(byte[] b, int off, int len) - Writes a portion of a byte array to the underlying stream.
|
void | write(int ch) - Writes a character to the underlying stream.
|
CR
public static final int CR
The CR octet.
- 13
LF
public static final int LF
The LF octet.
- 10
count
protected int count
The number of bytes in the line.
RFC2822OutputStream
public RFC2822OutputStream(OutputStream out)
Constructs an RFC2822 output stream
connected to the specified output stream.
out
- the underlying OutputStream
write
public void write(byte[] b)
throws IOException
Writes a byte array to the underlying stream.
write
public void write(byte[] b,
int off,
int len)
throws IOException
Writes a portion of a byte array to the underlying stream.
write
public void write(int ch)
throws IOException
Writes a character to the underlying stream.