Package de.huxhorn.lilith.sender
Class ZeroDelimitedWriteByteStrategy
- java.lang.Object
-
- de.huxhorn.lilith.sender.ZeroDelimitedWriteByteStrategy
-
- All Implemented Interfaces:
WriteByteStrategy
public class ZeroDelimitedWriteByteStrategy extends java.lang.Object implements WriteByteStrategy
-
-
Constructor Summary
Constructors Constructor Description ZeroDelimitedWriteByteStrategy()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
writeBytes(java.io.DataOutputStream dataOutputStream, byte[] bytes)
Writes the byte array if it contains any data, followed by a zero-byte.
-
-
-
Method Detail
-
writeBytes
public void writeBytes(java.io.DataOutputStream dataOutputStream, byte[] bytes) throws java.io.IOException
Writes the byte array if it contains any data, followed by a zero-byte.- Specified by:
writeBytes
in interfaceWriteByteStrategy
- Parameters:
dataOutputStream
- the stream the bytes will be written to.bytes
- the bytes that are written- Throws:
java.io.IOException
- if an exception is thrown while writing the bytes.
-
-