public class HexString extends Object
| Constructor and Description |
|---|
HexString() |
| Modifier and Type | Method and Description |
|---|---|
static byte[] |
fromHexString(String values)
Convert a string of hex values into a string of bytes
|
static String |
toHexString(byte[] bytes)
Convert a string of bytes to a ':' separated hex string
|
static String |
toHexString(long val) |
static String |
toHexString(long val,
int padTo) |
static long |
toLong(String value) |
public static String toHexString(byte[] bytes)
bytes - public static String toHexString(long val, int padTo)
public static String toHexString(long val)
public static byte[] fromHexString(String values) throws NumberFormatException
values - "0f:ca:fe:de:ad:be:ef"NumberFormatException - If the string can not be parsedpublic static long toLong(String value) throws NumberFormatException
NumberFormatExceptionCopyright © 2016. All rights reserved.