IRestApi助手

public interface IRestApiHelper

com.android.tradefed.util.IRestApiHelper


用於執行 REST API 呼叫的幫助程式介面。

概括

公共方法

abstract HttpResponse execute (String method, String[] uriParts, options, JSONObject data) execute (String method, String[] uriParts, options, JSONObject data)

執行 API 請求。

公共方法

執行

public abstract HttpResponse execute (String method, 
                String[] uriParts, 
                 options, 
                JSONObject data)

執行 API 請求。

參數
method String : 請求的 HTTP 方法

uriParts String :用於建構請求 URI 的 URL 編碼的 URI 部分。

options :用於建構查詢字串的未編碼參數名稱和值

data JSONObject :隨請求一起傳送的數據

退貨
HttpResponse一個 HttpResponse 對象

投擲
IO異常