update params from response data
772829
def _update_params(self):
        
        if self.data.get('title'):
            self.params['title'] = self.data.get('title')
        if self.data.get('pageid'):
            self.params['pageid'] = self.data.get('pageid')
        if self.data.get('wikibase'):
            self.params['wikibase'] = self.data.get('wikibase')
751065
def update_resource(self, path, data, if_match=None):
        """"""
        response = self._http_request(resource=path, method="PUT", body=data,
                                      if_match=if_match)
        try:
            return response.json()
        except ValueError:
            raise exception.ServiceException("Invalid service response.")
679212
def update_url_params(url, replace_all=False, **url_params):
    

    # Ensure 'replace_all' can be sent as a url param
    if not (replace_all is True or replace_all is False):
        url_params['replace_all'] = replace_all

    if not url or not url_params:
        return url or None

    scheme, netloc, url_path, url_query, fragment = _urlsplit(url)

    if replace_all is True:
        url_query = url_params
    else:
        url_query = _parse_qs(url_query)
        url_query.update(url_params)

    return _urlunsplit((scheme, netloc, url_path, _unquote(_urlencode(url_query, doseq=True)), fragment))
176986
def update_fields_values(params)
      params || return

      fields.each {|f| f.find_or_create_type_object(self).tap {|t| t || next
        params[f.code_name.to_sym].tap {|v| v && t.value = v}
        t.save }}
    end
521819
def format_parameters(self, params):
        # type: (Dict[str, str]) -> None
        
        query = urlparse(self.url).query
        if query:
            self.url = self.url.partition('?')[0]
            existing_params = {
                p[0]: p[-1]
                for p in [p.partition('=') for p in query.split('&')]
            }
            params.update(existing_params)
        query_params = ["{}={}".format(k, v) for k, v in params.items()]
        query = '?' + '&'.join(query_params)
        self.url = self.url + query
777031
def update_post(params)
      post_file   = params[:post][:name]
      post        = jekyll_post(post_file)
      yaml_config = merge_config(post.data, params)
      write_post_contents(params[:post][:content], yaml_config, post_file)

      post_file
    end
351111
def update
      post_params[:user_id] = @post.user_id
      respond_to do |format|
        if @post.update(post_params)
          format.json { render json: @post, status: 200 }
        else
          format.json { render json: @post.errors, status: :unprocessable_entity }
        end
      end
    end
162815
def updateParams(self, newvalues, update_all=False):
        """"""
        assert all(map(lambda x: x in self.freeparams, newvalues.keys())),\
                "Invalid entry in newvalues: {0}\nfreeparams: {1}".format(
                ', '.join(newvalues.keys()), ', '.join(self.freeparams))
        changed = set([]) # contains string names of changed params
        for (name, value) in newvalues.items():
            _checkParam(name, value, self.PARAMLIMITS, self.PARAMTYPES)
            if isinstance(value, scipy.ndarray):
                if (value != getattr(self, name)).any():
                    changed.add(name)
                    setattr(self, name, value.copy())
            else:
                if value != getattr(self, name):
                    changed.add(name)
                    setattr(self, name, copy.copy(value))

        if update_all or changed:
            self._cached = {}

        # The order of the updating below is important.
        # If you change it, you may break either this class
        # **or** classes that inherit from it.
        # Note also that not all attributes need to be updated
        # for all possible parameter changes, but just doing it
        # this way is much simpler and adds negligible cost.
        if update_all or (changed and changed != set(['mu'])):
            self._update_Pxy()
            self._update_Pxy_diag()
            self._update_dPxy()
            self._update_B()
855577
function updateFieldsRec(toData, fromData) {
        var keys = Object.keys(fromData),
            i;

        for (i = 0; i < keys.length; i += 1) {
            if (isTrueObject(fromData[keys[i]]) && isTrueObject(toData[keys[i]])) {
                updateFieldsRec(toData[keys[i]], fromData[keys[i]]);
            } else {
                toData[keys[i]] = fromData[keys[i]];
            }
        }
    }
389700
def params(self, dict):
        """"""
        self._configuration.update(dict)
        self._measurements.update()
763305
def update_self(parsed_response)
      instance_variables.each do |iv|
        instance_variable_set(iv, parsed_response[iv.to_s[1..-1].to_sym])
      end
      self
    end
1253986
function updateQueryStringParameter(uri, key, value) {
            var re = new RegExp("([?|&])" + key + "=.*?(&|#|$)", "i");

            if (uri.match(re)) {
                return uri.replace(re, '$1' + key + "=" + value + '$2');
            } else {
                var hash = '';

                if (uri.indexOf('#') !== -1) {
                    hash = uri.replace(/.*#/, '#');
                    uri = uri.replace(/#.*/, '');
                }

                var separator = uri.indexOf('?') !== -1 ? "&" : "?";
                return uri + separator + key + "=" + value + hash;
            }
        }
987817
def querystring_update(request, **kwargs):
    
    updated = request.GET.copy()
    for k, v in kwargs.items():
        updated[k] = v

    return updated.urlencode()
639417
def Update(self, data):
        
        m = len(data)
        self.params[:m] += data
76885
def build_params(self, params={}):
        
        z = params.copy()
        z.update({'editId': self.edit_id, 'packageName': self.package_name})
        return z
607939
def update(self, **kwargs):
        
        if not self.object_id:
            return False

        url = self.build_url(
            self._endpoints.get('item').format(id=self.object_id))

        data = {self._cc(key): value for key, value in kwargs.items() if
                key in {'name',
                        'description'}}  # convert keys to protocol casing
        if not data:
            return False

        response = self.con.patch(url, data=data)
        if not response:
            return False

        new_data = response.json()

        for key in data:
            value = new_data.get(key, None)
            if value:
                setattr(self, self.protocol.to_api_case(key), value)

        return True
461165
function update(req, res, next) {
    for (var key in req.body) {
      req.body[key] = utils.toNative(req.body[key])
    }
    var resource = db(req.params.resource)
      .update(utils.toNative(req._internal.filters.id), req.body)
    if (resource) {
      res.jsonp(resource)
    } else {
      res.status(404).jsonp({})
    }
  }