| Modifier and Type | Method and Description |
|---|---|
static String |
byteToHex(int value) |
static String |
dump(byte[] data,
long offset,
int index)
dump an array of bytes to a String
|
static String |
dump(byte[] data,
long offset,
int index,
int length)
dump an array of bytes to a String
|
static void |
dump(byte[] data,
long offset,
OutputStream stream,
int index)
dump an array of bytes to an OutputStream
|
static void |
dump(byte[] data,
long offset,
OutputStream stream,
int index,
int length)
dump an array of bytes to an OutputStream
|
static String |
intToHex(int value) |
static String |
longToHex(long value) |
static String |
shortToHex(int value) |
static char |
toAscii(int dataB) |
static String |
toHex(byte value)
Converts the parameter to a hex value.
|
static String |
toHex(byte[] value)
Converts the parameter to a hex value.
|
static String |
toHex(int value)
Converts the parameter to a hex value.
|
static String |
toHex(long value)
Converts the parameter to a hex value.
|
static String |
toHex(short value)
Converts the parameter to a hex value.
|
public static void dump(byte[] data,
long offset,
OutputStream stream,
int index,
int length)
throws IOException,
ArrayIndexOutOfBoundsException,
IllegalArgumentException
data - the byte array to be dumpedoffset - its offset, whatever that might meanstream - the OutputStream to which the data is to be
writtenindex - initial index into the byte arraylength - number of characters to outputIOException - is thrown if anything goes wrong writing
the data to streamArrayIndexOutOfBoundsException - if the index is
outside the data array's boundsIllegalArgumentException - if the output stream is
nullpublic static void dump(byte[] data,
long offset,
OutputStream stream,
int index)
throws IOException,
ArrayIndexOutOfBoundsException,
IllegalArgumentException
data - the byte array to be dumpedoffset - its offset, whatever that might meanstream - the OutputStream to which the data is to be
writtenindex - initial index into the byte arrayIOException - is thrown if anything goes wrong writing
the data to streamArrayIndexOutOfBoundsException - if the index is
outside the data array's boundsIllegalArgumentException - if the output stream is
nullpublic static String dump(byte[] data, long offset, int index)
data - the byte array to be dumpedoffset - its offset, whatever that might meanindex - initial index into the byte arrayArrayIndexOutOfBoundsException - if the index is
outside the data array's boundspublic static String dump(byte[] data, long offset, int index, int length)
data - the byte array to be dumpedoffset - its offset, whatever that might meanindex - initial index into the byte arraylength - number of characters to outputArrayIndexOutOfBoundsException - if the index is
outside the data array's boundspublic static char toAscii(int dataB)
public static String toHex(byte[] value)
value - The value to convertpublic static String toHex(short value)
value - The value to convertpublic static String toHex(byte value)
value - The value to convertpublic static String toHex(int value)
value - The value to convertpublic static String toHex(long value)
value - The value to convertpublic static String longToHex(long value)
public static String intToHex(int value)
public static String shortToHex(int value)
public static String byteToHex(int value)