Here you can find the source of toHexLiteral(int v)
public static String toHexLiteral(int v)
//package com.java2s; //License from project: LGPL public class Main { public static String toHexLiteral(int v) { return "0x" + Integer.toHexString(v); }//from w w w . ja v a 2 s. c o m }