code: public static String doRequestWithUrl(String url, String method, Map<String, String> header, Map<String, String> params, String charset) throws IOException {
      HttpURLConnection conn = null;
      String rsp = null;
  
      try {
        String ctype = "application/json";
        String query = buildQuery(params, charset);
        try {
          conn = getConnection(buildGetUrl(url, query), method, header, ctype);
        } catch (IOException e) {
          throw e;
        }
  
        try {
          rsp = getResponseAsString(conn);
        } catch (IOException e) {
          throw e;
        }
  
      } finally {
        if (conn != null) {
          conn.disconnect();
        }
      }
  
      return rsp;
    }
docs: 执行HTTP GET/DELETE请求。
  
  @param url     请求地址
  @param params  请求参数
  @param charset 字符集，如UTF-8, GBK, GB2312
  @return 响应字符串
  @throws IOException