code: public static boolean isAlphanumeric(String s) {
          if (isEmpty(s)) return defaultEmptyOK;
  
          // Search through string's characters one by one
          // until we find a non-alphanumeric character.
          // When we do, return false; if we don't, return true.
          for (int i = 0; i < s.length(); i++) {
              // Check that current character is number or letter.
              char c = s.charAt(i);
  
              if (!isLetterOrDigit(c)) return false;
          }
  
          // All characters are numbers or letters.
          return true;
      }
docs: Returns true if string s is English letters (A .. Z, a..z) and numbers only.
  
  NOTE: Need i18n version to support European characters.
  This could be tricky due to different character
  sets and orderings for various languages and platforms.