static String unicodeToASCII(String input) {
        boolean ascii = true;
        for (int i = 0; i < input.length(); i++) {
            if (input.charAt(i) > 0x7F) {
                ascii = false;
                break;
            }
        }

        if (ascii) { // skip possibly expensive processing
            return input;
        }
        return IDN.toASCII(input);
    }
Converts potentially Unicode input to punycode.
If conversion fails, returns the original input.

@param input the string to convert, not null
@return converted input, or original input if conversion fails
core/src/main/java/com/alibaba/fastjson2/schema/DomainValidator.java