public interface UncheckedRandomDataInput
Note: Calling these methods without proper boundary checks can lead to undefined results and even JVM crashes.
Modifier and Type | Method and Description |
---|---|
byte |
readByte(long offset)
Read a byte at an offset possibly not checking memory bounds.
|
int |
readInt(long offset)
Read an int at an offset possibly not checking memory bounds.
|
long |
readLong(long offset)
Read a long at an offset possibly not checking memory bounds.
|
short |
readShort(long offset)
Read a short at an offset possibly not checking memory bounds.
|
byte readByte(long offset) throws net.openhft.chronicle.core.io.ClosedIllegalStateException
Memory bounds must be checked before invoking this method or else the result is undefined and may lead to JVM crashes.
offset
- Offset position from which the byte is to be read.BufferUnderflowException
- If the offset is beyond the boundary of the data source.net.openhft.chronicle.core.io.ClosedIllegalStateException
- If the resource has been released or closed.net.openhft.chronicle.core.io.ThreadingIllegalStateException
- If this resource was accessed by multiple threads in an unsafe wayshort readShort(long offset) throws net.openhft.chronicle.core.io.ClosedIllegalStateException
Memory bounds must be checked before invoking this method or else the result is undefined and may lead to JVM crashes.
offset
- Offset position from which the short is to be read.BufferUnderflowException
- If the offset is beyond the boundary of the data source.net.openhft.chronicle.core.io.ClosedIllegalStateException
- If the resource has been released or closed.net.openhft.chronicle.core.io.ThreadingIllegalStateException
- If this resource was accessed by multiple threads in an unsafe wayint readInt(long offset) throws net.openhft.chronicle.core.io.ClosedIllegalStateException
Memory bounds must be checked before invoking this method or else the result is undefined and may lead to JVM crashes.
offset
- Offset position from which the integer is to be read.BufferUnderflowException
- If the offset is beyond the boundary of the data source.net.openhft.chronicle.core.io.ClosedIllegalStateException
- If the resource has been released or closed.net.openhft.chronicle.core.io.ThreadingIllegalStateException
- If this resource was accessed by multiple threads in an unsafe waylong readLong(long offset) throws net.openhft.chronicle.core.io.ClosedIllegalStateException
Memory bounds must be checked before invoking this method or else the result is undefined and may lead to JVM crashes.
offset
- Offset position from which the long is to be read.BufferUnderflowException
- If the offset is beyond the boundary of the data source.net.openhft.chronicle.core.io.ClosedIllegalStateException
- If the resource has been released or closed.net.openhft.chronicle.core.io.ThreadingIllegalStateException
- If this resource was accessed by multiple threads in an unsafe wayCopyright © 2023. All rights reserved.