BigInteger (@NotNull String text) { if (text.equalsIgnoreCase("0" + retrieveSuffix(text))) { return BigInteger.ZERO; } final int beginIndex; final int radix; if (StringUtil.startsWithIgnoreCase(text, "0x")) { beginIndex = 2; radix = 16; } else if (StringUtil.startsWithIgnoreCase(text, "0b")) { beginIndex = 2; radix = 2; } else if (text.startsWith("0")) { if (StringUtil.isChar(text, 1, 'o') || StringUtil.isChar(text, 1, 'O')) { beginIndex = 2; } else { beginIndex = 1; } radix = 8; } else { beginIndex = 0; radix = 10; } return new BigInteger(prepareLiteralForJava(text, beginIndex), radix); }