public static String random(int length) {
        return new RandomStringGenerator.Builder()
                .filteredBy(NUMBERS, LETTERS)
                .build().generate(length);
    }
public static String random(int length) {
        return new RandomStringGenerator.Builder()
                .filteredBy(NUMBERS, LETTERS)
                .build().generate(length);
    }
public static String random ( int length ) { return new RandomStringGenerator . Builder ( ) . filteredBy ( NUMBERS , LETTERS ) . build ( ) . generate ( length ) ; }
Generate a random string with ASCII letters and digits.

@param length length of the generated string
@return generated string
Generate a random string with ASCII letters and digits .