Package com.sun.mail.util
Class LineOutputStream
- java.lang.Object
-
- java.io.OutputStream
-
- java.io.FilterOutputStream
-
- com.sun.mail.util.LineOutputStream
-
- All Implemented Interfaces:
Closeable
,Flushable
,AutoCloseable
public class LineOutputStream extends FilterOutputStream
This class is to support writing out Strings as a sequence of bytes terminated by a CRLF sequence. The String must contain only US-ASCII characters.The expected use is to write out RFC822 style headers to an output stream.
-
-
Constructor Summary
Constructors Constructor Description LineOutputStream(OutputStream out)
LineOutputStream(OutputStream out, boolean allowutf8)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
writeln()
void
writeln(String s)
-
Methods inherited from class java.io.OutputStream
nullOutputStream
-
-
-
-
Constructor Detail
-
LineOutputStream
public LineOutputStream(OutputStream out)
-
LineOutputStream
public LineOutputStream(OutputStream out, boolean allowutf8)
- Parameters:
out
- the OutputStreamallowutf8
- allow UTF-8 characters?- Since:
- JavaMail 1.6
-
-
Method Detail
-
writeln
public void writeln(String s) throws IOException
- Throws:
IOException
-
writeln
public void writeln() throws IOException
- Throws:
IOException
-
-