public static String intToHex(Integer i) {
        return prepareNumberHexString(i.longValue(), true, false, HEX_LEN_MIN, HEX_LEN_INT_MAX);
    }
@Test
    public void intToHex_Test() {
        Assertions.assertEquals("FFF5EE", TbUtils.intToHex(-2578));
        Assertions.assertEquals("0xFFD8FFA6", TbUtils.intToHex(0xFFD8FFA6, true, true));
        Assertions.assertEquals("0xA6FFD8FF", TbUtils.intToHex(0xFFD8FFA6, false, true));
        Assertions.assertEquals("0x7FFFFFFF", TbUtils.intToHex(Integer.MAX_VALUE, true, true));
        Assertions.assertEquals("0x80000000", TbUtils.intToHex(Integer.MIN_VALUE, true, true));
        Assertions.assertEquals("0xAB", TbUtils.intToHex(0xAB, true, true));
        Assertions.assertEquals("0xABCD", TbUtils.intToHex(0xABCD, true, true));
        Assertions.assertEquals("0xABCDEF", TbUtils.intToHex(0xABCDEF, true, true));
        Assertions.assertEquals("0xCDAB", TbUtils.intToHex(0xABCDEF, false, true, 4));
        Assertions.assertEquals("0xAB", TbUtils.intToHex(171, true, true));
        Assertions.assertEquals("0xAB", TbUtils.intToHex(0xAB, false, true));
        Assertions.assertEquals("0xAB", TbUtils.intToHex(0xAB, true, true, 2));
        Assertions.assertEquals("AB", TbUtils.intToHex(0xAB, false, false, 2));
        Assertions.assertEquals("AB", TbUtils.intToHex(171, true, false));
        Assertions.assertEquals("0xAB", TbUtils.intToHex(0xAB, true, true));
        Assertions.assertEquals("0xAB", TbUtils.intToHex(0xAB, false, true));
        Assertions.assertEquals("AB", TbUtils.intToHex(0xAB, false, false));

        Assertions.assertEquals("0xABCD", TbUtils.intToHex(0xABCD, true, true));
        Assertions.assertEquals("0xCDAB", TbUtils.intToHex(0xABCD, false, true));
        Assertions.assertEquals("0xCD", TbUtils.intToHex(0xABCD, true, true, 2));
        Assertions.assertEquals("AB", TbUtils.intToHex(0xABCD, false, false, 2));
    }