getRandomString static method
Implementation
static String getRandomString(int length) {
String charList =
"0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz";
String result = "";
Random f = new Random();
for (int i = 0; i < length; i++) {
result += charList[f.nextInt(charList.length)];
}
return result;
}