public interface BytesPrepender<B extends BytesPrepender<B>>
| Modifier and Type | Method and Description |
|---|---|
B |
clearAndPad(long length)
Clear a buffer, with a given padding to allow for prepending later.
|
default B |
prepend(long value)
Prepends a long in decimal, this method moves the readPosition() backwards.
|
B |
prewrite(byte[] bytes)
Write backward in binary a byte
|
B |
prewrite(BytesStore bytes)
Write backward in binary a byte
|
B |
prewriteByte(byte b)
Write backward in binary a byte
|
B |
prewriteInt(int i)
Write backward in binary a 4 byte int
|
B |
prewriteLong(long l)
Write backward in binary an 8 byte long
|
B |
prewriteShort(short i)
Write backward in binary a 2 byte int
|
@NotNull B clearAndPad(long length) throws BufferOverflowException
length - to padBufferOverflowException - if the length > capacity() - start()@NotNull default B prepend(long value) throws BufferOverflowException
Note: it moves the readPosition not the writePosition / readLimit
value - to prepend as text.BufferUnderflowException - if the capacity of the underlying buffer was exceedednet.openhft.chronicle.core.io.IORuntimeException - if an error occurred while attempting to resize the underlying bufferBufferOverflowException@NotNull B prewrite(byte[] bytes)
Note: it moves the readPosition not the writePosition / readLimit
bytes - to prepend to.@NotNull B prewrite(BytesStore bytes)
Note: it moves the readPosition not the writePosition / readLimit
bytes - to prepend to.@NotNull B prewriteByte(byte b)
Note: it moves the readPosition not the writePosition / readLimit
b - byte to prepend to.@NotNull B prewriteShort(short i)
Note: it moves the readPosition not the writePosition / readLimit
i - short to prepend to.@NotNull B prewriteInt(int i)
Note: it moves the readPosition not the writePosition / readLimit
i - integer to prepend to.@NotNull B prewriteLong(long l)
Note: it moves the readPosition not the writePosition / readLimit
l - long to prepend to.Copyright © 2017. All rights reserved.