code: public static String escapeString(String input) {
          StringBuilder escaped = new StringBuilder(input.length() + 10);
          escaped.append('"');
          for (int i = 0; i < input.length(); i++) {
              if (input.charAt(i) == '"') {
                  escaped.append("\"\"");
              } else {
                  escaped.append(input.charAt(i));
              }
          }
          escaped.append('"');
          return escaped.toString();
      }
docs: Escape given string so that tokenize(escapeString(str)).get(0).getString === str.
  @param input String to be escaped
  @return escaped string