class StringUtil {

    public static boolean isAscii(@NonNull String text) {
        Objects.requireNonNull(text, "text is null");
        return StandardCharsets.US_ASCII.newEncoder().canEncode(text);
    }

}