public class ZeroDelimitedWriteByteStrategy extends java.lang.Object implements WriteByteStrategy
Constructor and Description |
---|
ZeroDelimitedWriteByteStrategy() |
Modifier and Type | Method and Description |
---|---|
void |
writeBytes(java.io.DataOutputStream dataOutputStream,
byte[] bytes)
Writes the byte array if it contains any data, followed by a zero-byte.
|
public void writeBytes(java.io.DataOutputStream dataOutputStream, byte[] bytes) throws java.io.IOException
writeBytes
in interface WriteByteStrategy
dataOutputStream
- the stream the bytes will be written to.bytes
- the bytes that are writtenjava.io.IOException
- if an exception is thrown while writing the bytes.