writeTo

Writes the complete contents of this ByteArrayOutputStream to the specified output stream argument, as if by calling the output stream's write method using out.write(buf, 0, count).

Parameters

out

the output stream to which to write the data.

Throws

if out is null.

okio.IOException

if an I/O error occurs.