public abstract class InfiniumDataFile
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static char[] |
byteArrayToCharArray(byte[] stringBytes) |
static float |
byteArrayToFloat(byte[] bytes)
Utility method to convert a byte array to a float value.
|
static int |
byteArrayToInt(byte[] bytes)
Utility method to convert an unsigned short to an int.
|
static byte[] |
floatToByteArray(float floatValue)
Utility method to convert a float to a byte array
|
java.lang.String |
getIdentifier() |
void |
setIdentifier(java.lang.String identifier) |
static byte[] |
shortToByteArray(short value)
Utility method to convert a short to a byte array
|
public static char[] byteArrayToCharArray(byte[] stringBytes)
public static int byteArrayToInt(byte[] bytes)
bytes
- The byte array representing the unsigned short.
(Java has no unsigned values which is why we promote it to an int)public static byte[] shortToByteArray(short value)
value
- The short value to convert to byte arraypublic static float byteArrayToFloat(byte[] bytes)
bytes
- The byte array representing the float value.public static byte[] floatToByteArray(float floatValue)
floatValue
- the float value to convert to byte arraypublic java.lang.String getIdentifier()
public void setIdentifier(java.lang.String identifier)