<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                服務器無法訪問外網, 使用者也是內網, 有另一個服務器是專門做代理機的, 前端訪問后臺的接口, 后臺通過代理機調用天地圖 天地圖提示418時,看看url地址是不是正確. ``` networkIp networkPort 代理機的ip和端口 HttpUtil 是hutool工具類 調用: 接口地址?T=cva\_w&x=55&y=25&l=6&tk=換成自己的key private String[] tarr = new String[]{"t3","t4","t5","t6"}; 這個是只使用了瓦片, 前端用的其他GIS代碼, 這些參數是其處理時設置的訪問天地圖地震, 參數和那個一樣 public void tianditu(@RequestParam String T, @RequestParam String tk, @RequestParam String x, @RequestParam String y, @RequestParam String l, HttpServletResponse response) { try { String t4 = tarr[RandomUtil.randomInt(0, 4)]; String url = "http://"+t4+".tianditu.com/DataServer?T=" + T + "&tk="+tk+"&x="+x+"&y="+y+"&l="+l; HttpResponse httpResponse = HttpUtil.createGet(url, true) .setHttpProxy(networkIp, networkPort).executeAsync(); OutputStream out = response.getOutputStream(); // 寫入內容 httpResponse.writeBody(out, false, null); // 執行寫入 刷新此輸出流并強制寫入任何緩沖的輸出字節 out.flush(); } catch (Exception e) { log.error("tianditu 天地圖代理訪問", e); } } url 是完整的請求地址, 注意傳參時要把完整地址都設置為url的參數, 否則會導致天地圖路徑上的?&的參數被識別為這個請求的 接口地址?url=https://api.tianditu.gov.cn/api?v=4.0%26tk=換成自己的key public void tdt(String url, HttpServletResponse response) { try { HttpResponse httpResponse = HttpUtil.createGet(url, true) .setHttpProxy(networkIp, networkPort).executeAsync(); OutputStream out = response.getOutputStream(); // 寫入內容 httpResponse.writeBody(out, false, null); // 執行寫入 刷新此輸出流并強制寫入任何緩沖的輸出字節 out.flush(); } catch (Exception e) { log.error("tianditu 天地圖代理訪問", e); } } ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看