code: public static boolean needsQuoting(String str) {
      if (str == null) {
        return false;
      }
      byte[] bytes = str.getBytes();
      return needsQuoting(bytes, 0 , bytes.length);
    }
docs: Does the given string need to be quoted?
  @param str the string to check
  @return does the string contain any of the active html characters?