Java Utililty Methods OutputStream Write Byte Array

List of utility methods to do OutputStream Write Byte Array

Description

The list of methods to do OutputStream Write Byte Array are organized into topic(s).

Method

voidwriteBytesToStream(byte[] bytes, OutputStream outputStream)
Writes given bytes array to given outputStream.
BufferedOutputStream bos = new BufferedOutputStream(outputStream);
try {
    bos.write(bytes);
} finally {
    bos.close();
voidwriteBytesToStream(byte[] data, OutputStream os)
Write a byte array into an output stream.
ByteArrayInputStream bais = new ByteArrayInputStream(data);
copyStream(bais, os);
bais.close();