Android REST API using PATCH method

后端 未结 1 386
梦毁少年i
梦毁少年i 2021-02-11 10:35
 HttpClient httpClient = new DefaultHttpClient(); 

    try {
        HttpPost request = new HttpPost(strUrl);

        StringEntity params =new StringEntity(json.toStri         


        
1条回答
  •  深忆病人
    2021-02-11 11:13

    Download httpclient-4.2.jar file.

    import below files

    import org.apache.http.message.AbstractHttpMessage; import org.apache.http.client.methods.HttpRequestBase; import org.apache.http.client.methods.HttpEntityEnclosingRequestBase; import org.apache.http.client.methods.HttpPatch;

    Put

    HttpPatch request = new HttpPatch(strUrl);

    Insted of

    HttpPost request = new HttpPost(strUrl);
    

    0 讨论(0)
提交回复
热议问题