public class CramInt extends Object
| Constructor | Description |
|---|---|
CramInt() |
| Modifier and Type | Method | Description |
|---|---|---|
static int |
int32(byte[] data) |
Read unsigned little-endian 4 byte integer from an array of bytes.
|
static int |
int32(InputStream inputStream) |
Read unsigned little-endian 4 byte integer from an
InputStream. |
static int |
int32(ByteBuffer buffer) |
Read unsigned little-endian 4 byte integer from an
ByteBuffer. |
static byte[] |
writeInt32(int value) |
Write int value to
OutputStream encoded as CRAM int data type. |
static int |
writeInt32(int value,
OutputStream outputStream) |
Write int value to
OutputStream encoded as CRAM int data type. |
public static int int32(InputStream inputStream) throws IOException
InputStream.inputStream - input stream to read fromIOException - as per java IO contractpublic static int int32(byte[] data)
data - input stream to read frompublic static int int32(ByteBuffer buffer)
ByteBuffer.buffer - ByteBuffer to read frompublic static int writeInt32(int value,
OutputStream outputStream)
throws IOException
OutputStream encoded as CRAM int data type.value - value to be written outoutputStream - the output streamIOException - as per java IO contractpublic static byte[] writeInt32(int value)
OutputStream encoded as CRAM int data type.value - value to be written out