public static int isHexadecimal(String str) {
        if (str == null || str.isEmpty()) {
            return -1;
        }
        return str.matches("^-?(0[xX])?[0-9a-fA-F]+$") ? HEX_RADIX : -1;
    }
@Test
    public void isHexadecimal_Test() {
        Assertions.assertEquals(16, TbUtils.isHexadecimal("F5D7039"));
        Assertions.assertEquals(-1, TbUtils.isHexadecimal("K100110"));
    }