public class Utils extends Object
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
byteArrayFromInt(int value)
Creates a byte array with a int inside
|
static String |
bytesToHex(byte[] bytes)
Transforms a byte array in an almost readable string
|
static byte[] |
readFully(InputStream is,
int length)
Fully read an input stream and returns the bytes
|
public static String bytesToHex(byte[] bytes)
bytes - the bytes to printpublic static byte[] byteArrayFromInt(int value)
value - the int valuepublic static byte[] readFully(InputStream is, int length) throws IOException
is - the input streamlength - the length to readIOExceptionCopyright © 2021. All rights reserved.