Package org.apache.kerby.util
Class HexUtil
java.lang.Object
org.apache.kerby.util.HexUtil
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringbytesToHex(byte[] bytes) Convert bytes into format as: 02020080static StringbytesToHexFriendly(byte[] bytes) Convert bytes into friendly format as: 0x02 02 00 80static byte[]Convert hex string like follows into byte array 02020080static byte[]hex2bytesFriendly(String hexString) Convert friendly hex string like follows into byte array 0x02 02 00 80
-
Method Details
-
bytesToHexFriendly
Convert bytes into friendly format as: 0x02 02 00 80- Parameters:
bytes- The bytes to be converted- Returns:
- The hex string
-
hex2bytesFriendly
Convert friendly hex string like follows into byte array 0x02 02 00 80- Parameters:
hexString- The hex string- Returns:
- The bytes
-
bytesToHex
Convert bytes into format as: 02020080- Parameters:
bytes- The bytes- Returns:
- The hex string
-
hex2bytes
Convert hex string like follows into byte array 02020080- Parameters:
hexString- The hex string- Returns:
- The bytes
-