當前位置: 首頁>>代碼示例>>Java>>正文


Java RequestException.printStackTrace方法代碼示例

本文整理匯總了Java中com.google.gwt.http.client.RequestException.printStackTrace方法的典型用法代碼示例。如果您正苦於以下問題:Java RequestException.printStackTrace方法的具體用法?Java RequestException.printStackTrace怎麽用?Java RequestException.printStackTrace使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在com.google.gwt.http.client.RequestException的用法示例。


在下文中一共展示了RequestException.printStackTrace方法的7個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: load

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
public void load(String url, final String regionName) {
    RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, url);
    try {
        builder.sendRequest(null, new RequestCallback(){
            public void onResponseReceived(com.google.gwt.http.client.Request req, Response res) {
                updateHtml(res.getText(), regionName);
            }

            public void onError(com.google.gwt.http.client.Request request, Throwable exception) {
            }
        });
    } catch (RequestException e) {
        e.printStackTrace();
    }

}
 
開發者ID:lsst,項目名稱:firefly,代碼行數:17,代碼來源:HtmlRegionLoader.java

示例2: setAnnotationsHTMLURL

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
public void setAnnotationsHTMLURL(String url) {
	RequestBuilder sendRequest = new RequestBuilder(RequestBuilder.GET, UriUtils.sanitizeUri(url));
	try {
		sendRequest.sendRequest(null, annotationsHTMLCallback);
	} catch (RequestException e) {
		e.printStackTrace();
	}
}
 
開發者ID:NOAA-PMEL,項目名稱:LAS,代碼行數:9,代碼來源:LASAnnotationsPanel.java

示例3: sendRequest

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
private void sendRequest(String url, RequestCallback callback) {
    RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, URL.encode(url));
    builder.setHeader("Accept", "application/json");
    
    builder.setUser("ipv6Rest");
    builder.setPassword("ipv6Rest");
    try {
        builder.sendRequest(null, callback);
    } catch (RequestException e) {
        e.printStackTrace();
    }
}
 
開發者ID:qoswork,項目名稱:opennmszh,代碼行數:13,代碼來源:DefaultChartService.java

示例4: sendRequest

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
private void sendRequest(RequestCallback callback, String url) {
    RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, URL.encode(url));
    builder.setHeader("accept", "application/json");
    try {
        builder.sendRequest(null, callback);
    } catch (RequestException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
    }
}
 
開發者ID:qoswork,項目名稱:opennmszh,代碼行數:11,代碼來源:DefaultNodeService.java

示例5: sendRequest

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
private void sendRequest(final RequestCallback callback, final Method method, final String url) {
    final RequestBuilder builder = new RequestBuilder(method, url);
    builder.setHeader("accept", "application/json");
    try {
        builder.sendRequest(null, callback);
    } catch (final RequestException e) {
        e.printStackTrace();
    }
}
 
開發者ID:qoswork,項目名稱:opennmszh,代碼行數:10,代碼來源:DefaultKscReportService.java

示例6: sendRequest

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
private void sendRequest(RequestCallback callback, String url) {
    RequestBuilder builder = new RequestBuilder(RequestBuilder.GET, URL.encode(url));
    builder.setHeader("accept", "application/json");
    try {
        builder.sendRequest(null, callback);
    } catch (RequestException e) {
        e.printStackTrace();
    }
}
 
開發者ID:qoswork,項目名稱:opennmszh,代碼行數:10,代碼來源:DefaultNodeService.java

示例7: update

import com.google.gwt.http.client.RequestException; //導入方法依賴的package包/類
public void update() {
  try {
    if (waitingForResponse) {
      return;
    }
    waitingForResponse = true;
    // Using a reusable builder makes IE fail because it caches the response
    // So it's better to change the request path sending an additional random parameter
    RequestBuilder reqBuilder = new RequestBuilder(RequestBuilder.GET, composeURL("filename=" + fileInput.getName() , "c=" + requestsCounter++));
    reqBuilder.setTimeoutMillis(DEFAULT_AJAX_TIMEOUT);
    reqBuilder.sendRequest("get_status", onStatusReceivedCallback);
  } catch (RequestException e) {
    e.printStackTrace();
  }
}
 
開發者ID:mwl,項目名稱:gwt-upload,代碼行數:16,代碼來源:Uploader.java


注:本文中的com.google.gwt.http.client.RequestException.printStackTrace方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。