mirror of
https://github.com/i-net-software/JWebAssembly.git
synced 2025-03-25 07:27:52 +01:00
add method writeTo()
This commit is contained in:
parent
984cfb2bc5
commit
e9e7d1aecc
@ -130,4 +130,16 @@ class WasmOutputStream extends FilterOutputStream {
|
|||||||
baos.writeTo( this );
|
baos.writeTo( this );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Write the data of this stream to the output. Work only for in memory stream.
|
||||||
|
*
|
||||||
|
* @param output
|
||||||
|
* the target
|
||||||
|
* @throws IOException
|
||||||
|
* if any I/O error occur
|
||||||
|
*/
|
||||||
|
void writeTo( OutputStream output ) throws IOException {
|
||||||
|
ByteArrayOutputStream baos = (ByteArrayOutputStream)out;
|
||||||
|
baos.writeTo( output );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user