Class ByteUtils
java.lang.Object
org.bitcoinj.secp.internal.ByteUtils
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic intcompareUnsigned(byte[] a, byte[] b) Compare byte arrays treating each byte as unsigned.static StringtoHexString(byte[] bytes) Utility method to format hex bytes as string
-
Constructor Details
-
ByteUtils
public ByteUtils()
-
-
Method Details
-
compareUnsigned
public static int compareUnsigned(byte[] a, byte[] b) Compare byte arrays treating each byte as unsigned.- Parameters:
a- byte array to compareb- byte array to compare- Returns:
- a negative integer if
a < b, zero ifa == b, or a positive integer ifa > b
-
toHexString
Utility method to format hex bytes as string- Parameters:
bytes- bytes to format- Returns:
- hex-formatted String
-