This method implements an HTTP put. Use this method to update a resource.

@param uri the URI
@param params the parameters.
@return the put response.
@throws IOException unexpected exception.
@throws AppPlatformException unexpected exception.
340492
public RestResponse put(final String uri, final Map<String, Object> params) throws IOException,
            AppPlatformException {
        return request(getPath(uri), HttpPut.METHOD_NAME, params);
    }
1080632
public Response put(String restPath, Object payload, Map<String, String> queryParams) {
		LOG.debug("PUT: {}", restPath);
		return call(HttpMethod.PUT, restPath, Response.class, payload, queryParams);
	}
488083
public QYResultType update(Map<String, Object> params){
        String url = BASE_API_URL + "cgi-bin/agent/set?access_token=#";
        BaseResponse response = executePost(url, JSONUtil.toJson(params));
        return QYResultType.get(response.getErrcode());
    }
323111
public T httpPost(final URI uri, final List<Pair<String, String>> params) throws IOException {
    // shortcut if the passed url is invalid.
    if (null == uri) {
      logger.error(" unable to perform httpPost as the passed uri is null.");
      return null;
    }

    final HttpPost post = new HttpPost(uri);
    return this.sendAndReturn(completeRequest(post, params));
  }
183864
public RestResponse postJson(final String uri, final String params)
            throws IOException, AppPlatformException {
        return requestJson(getPath(uri), HttpPost.METHOD_NAME, params);
    }
435720
public XcapResponse putIfMatch(URI uri, String eTag, String mimetype,
			String content, Header[] additionalRequestHeaders,
			Credentials credentials) throws IOException {

		if (log.isDebugEnabled()) {
			log.debug("putIfMatch(uri=" + uri + ", eTag=" + eTag
					+ ", mimetype=" + mimetype + ", content=" + content
					+ " , additionalRequestHeaders = ( "
					+ Arrays.toString(additionalRequestHeaders) + " ) )");
		}

		final HttpPut request = new HttpPut(uri);
		setRequestEntity(request, content, mimetype);
		request.setHeader(XcapConstant.HEADER_IF_MATCH, eTag);
		return execute(request, additionalRequestHeaders, credentials);

	}
1366800
public Response put(String path) throws IOException, RESTException {
        return put(path, null, null);
    }
962958
public RestResponse get(final String uri, final Map<String, Object> params) throws Exception {
        final String path = getPath(uri);
        final RestResponse response = request(path, HttpGet.METHOD_NAME, params);
        if (response.isError()) {
            throw new IOException(response.getResponseText());
        }
        return response;
    }
767228
public Response put(InputStream inputStream, long size, String key, String token, StringMap params,
                        String mime, boolean checkCrc) throws QiniuException {
        if (size < 0 || size > configuration.putThreshold) {
            return put(inputStream, key, token, params, mime);
        }
        byte[] data = null;
        try {
            data = IOUtils.toByteArray(inputStream);
        } catch (IOException e) {
            throw new QiniuException(e);
        }
        return put(data, key, token, params, mime, checkCrc);
    }
254904
public static Put put(String uri, byte[] content) {
        return put(uri, content, CONNECTION_TIMEOUT , READ_TIMEOUT);
    }
66656
public static HttpRequestBase put(String path,
	                                  Map<String, String> headers,
	                                  Map<String, String> parameters,
	                                  Integer timeOutInSeconds) {

		return put(path, headers, parameters, null, timeOutInSeconds);
	}
219535
public function put($url, array $params = [])
    {
        return $this->request($this->createUrl($url), self::METHOD_PUT, $params);
    }
421681
public String post(String endpoint, String params) throws IOException {
        return this.post(endpoint, params, "");
    }
1190085
public static Response put(String uriString, String username, String password) throws URISyntaxException, HttpException {
        return putBody(new HttpPut(uriString), null, null, new UsernamePasswordCredentials(username, password), null);
    }
926379
public function put($url, $params = null) {
    $this->params = $params;
    $this->method = 'PUT';
    $this->url = $url;

    return $this->request();
  }
390977
Response put(URI uri, InputStream instream, String contentType) {
        HttpConnection connection = Http.PUT(uri, contentType);

        connection.setRequestBody(instream);

        return executeToResponse(connection);
    }
638541
private void addParams(RequestBuilder call, Param[] params) {
		
		// Once upon a time this was necessary, now it isn't
		//call.addParam("format", "json");
		
		if (this.accessToken != null)
			call.addParam("access_token", this.accessToken);

		if (this.appSecretProof != null)
			call.addParam("appsecret_proof", this.appSecretProof);

		if (params != null) {
			for (Param param: params) {
				if (param instanceof BinaryParam) {
					call.addParam(param.name, (InputStream)param.value, ((BinaryParam)param).contentType, "irrelevant");
				} else {
					String paramValue = StringUtils.stringifyValue(param, this.mapper);
					call.addParam(param.name, paramValue);
				}
			}
		}
	}