Code example for HttpPut

Methods: addHeader

0
    	return null; 
    } 
     
    public JSONObject put(String url, JSONObject json) {
        // Prepare a request object 
        HttpPut httpput = new HttpPut(url); 
         
        httpput.addHeader("Content-Type", "application/json");
        httpput.addHeader("Accept", "application/json");
         
        try { 
			httpput.setEntity(new StringEntity(json.toString()));
		} catch (UnsupportedEncodingException e) {
			// TODO Auto-generated catch block 
			e.printStackTrace();
		} 
         
        return this.execute(httpput);
    } 
     
    public JSONObject get(String url)