Java int zu hex feste Länge
//You can replace X with x to get lower case hex characters
//Replace the 2 with the amount of digits you want
String.format("%02X", value);
Elegant Echidna