public class HeaderWriter extends Object
This class is designed to be thread safe to be used across multiple producers and makes the header visible in the correct order for consumers.
| Modifier and Type | Method and Description |
|---|---|
static HeaderWriter |
newInstance(UnsafeBuffer defaultHeader)
Create a new
HeaderWriter that is ByteOrder specific to the platform. |
void |
write(UnsafeBuffer termBuffer,
int offset,
int length,
int termId)
Write a header to the term buffer in
ByteOrder.LITTLE_ENDIAN format using the minimum instructions. |
public static HeaderWriter newInstance(UnsafeBuffer defaultHeader)
HeaderWriter that is ByteOrder specific to the platform.defaultHeader - for the stream.HeaderWriter that is ByteOrder specific to the platform.public void write(UnsafeBuffer termBuffer, int offset, int length, int termId)
ByteOrder.LITTLE_ENDIAN format using the minimum instructions.termBuffer - to be written to.offset - at which the header should be written.length - of the fragment including the header.termId - of the current term buffer.Copyright © 2014-2023 Real Logic Limited. All Rights Reserved.