encode

fun encode(in: InputStream, out: OutputStream, lineSep: Boolean)

Encodes a raw InputStream into a BASE64 OutputStream representation in accordance with RFC 2045. This implementation was inspired by MIG Base64 encodeToByte

Parameters

in
out
lineSep

Optional "\r\n" after 76 characters, unless end of file.No line separator will be in breach of RFC 2045 which specifies max 76 per line but will be a little faster.

Throws