Update existing shortlink registration

        Arguments:
            shortlink_id:
                Shortlink id assigned by mCASH
358958
def update_shortlink(self, shortlink_id, callback_uri=None,
                         description=None):
        
        arguments = {'callback_uri': callback_uri,
                     'description': description}
        return self.do_req('PUT',
                           self.merchant_api_base_url + '/shortlink/' +
                           shortlink_id + '/', arguments)
497140
def shortcut_update(self, shortcut_id, data, **kwargs):
        ""
        api_path = "/api/v2/shortcuts/{shortcut_id}"
        api_path = api_path.format(shortcut_id=shortcut_id)
        return self.call(api_path, method="PUT", data=data, **kwargs)
512946
def register_mime(shortname, mime_types):
    
    if shortname in _MIME_TYPES:
        raise MimeRenderException('"%s" has already been registered'%shortname)
    _MIME_TYPES[shortname] = mime_types
181952
def update(self, id):
        """"""
        map = self._get_map_from_user_by_id(c.user, id)
        if map is None:
            abort(404)

        # get json content from PUT request
        content = request.environ['wsgi.input'].read(int(request.environ['CONTENT_LENGTH']))
        #content = content.decode('utf8')

        # update mapfile
        mapfile = Mapfile()
        dict = simplejson.loads(content)
        mapfile.from_dict(dict)
        mapfile.to_file(os.path.join(config['mapfiles_dir'], map.filepath))
        if mapfile.get_name() != map.name:
            self._update_map(map, name=mapfile.get_name())

        response.status = 201
        return
602746
def update_active_id_list(self, update_active_ids_finished_cb):
        """"""
        if not self._update_active_ids_finished_cb:
            self._update_active_ids_finished_cb = update_active_ids_finished_cb
            self.active_anchor_ids = []

            self.active_ids_valid = False

            logger.debug('Updating active ids of memory {}'.format(self.id))

            # Start reading the header
            self.mem_handler.read(self, LocoMemory2.ADR_ACTIVE_ID_LIST,
                                  LocoMemory2.ID_LIST_LEN)
1180533
def update(self, sid, **kwargs):
        
        item = self[sid]
        for attribute, value in kwargs.items():
            item[attribute] = value
        self[sid] = item
682643
def shortid
      len = 6
      loop do
        begin
          self.class.expand(@id.shorten(len))
          break
        rescue Familia::NonUniqueKey
          len += 1
        end
      end
      @id.shorten(len) 
    end
371618
def update_identity(self, identity, identity_id):
        
        route_values = {}
        if identity_id is not None:
            route_values['identityId'] = self._serialize.url('identity_id', identity_id, 'str')
        content = self._serialize.body(identity, 'Identity')
        self._send(http_method='PUT',
                   location_id='28010c54-d0c0-4c89-a5b0-1c9e188b9fb7',
                   version='5.0',
                   route_values=route_values,
                   content=content)
21022
def update(self, uid):
        '''
        
        '''
        if self.userinfo.role[1] >= '3':
            pass
        else:
            return False
        post_data = self.get_post_data()

        post_data['user_name'] = self.get_current_user()

        if self.is_p:
            if MLink.update(uid, post_data):
                output = {
                    'addinfo ': 1,
                }
            else:
                output = {
                    'addinfo ': 0,
                }
            return json.dump(output, self)
        else:
            if MLink.update(uid, post_data):
                self.redirect('/link/list')
1010588
def _registry_update(s, oldid):
        '''
        
        '''
        with _lock:
            sock_queue = ApplicationLayer._to_app.pop(oldid)
            ApplicationLayer._to_app[s._sockid()] = sock_queue
1194458
def update(self, cluster_template_id, name=NotUpdated,
               plugin_name=NotUpdated, plugin_version=NotUpdated,
               description=NotUpdated, cluster_configs=NotUpdated,
               node_groups=NotUpdated, anti_affinity=NotUpdated,
               net_id=NotUpdated, default_image_id=NotUpdated,
               use_autoconfig=NotUpdated, shares=NotUpdated,
               is_public=NotUpdated, is_protected=NotUpdated,
               domain_name=NotUpdated):
        """"""

        data = {}
        self._copy_if_updated(data, name=name,
                              plugin_name=plugin_name,
                              plugin_version=plugin_version,
                              description=description,
                              cluster_configs=cluster_configs,
                              node_groups=node_groups,
                              anti_affinity=anti_affinity,
                              neutron_management_network=net_id,
                              default_image_id=default_image_id,
                              use_autoconfig=use_autoconfig,
                              shares=shares,
                              is_public=is_public,
                              is_protected=is_protected,
                              domain_name=domain_name)

        return self._patch('/cluster-templates/%s' % cluster_template_id,
                           data, 'cluster_template')
1127906
def update_plugin(plugin_id):
    
    try:
        instance = CMSPlugin.objects.get(id=plugin_id).get_plugin_instance()[0]
        instance.update()
    except:
        return None, 0
    return instance, instance.posts.count()
1317392
def update_backends(cls, id_mapping, custom_trees, backend=None):
        
        backend = Store.current_backend if backend is None else backend
        # Update the custom option entries for the current backend
        Store.custom_options(backend=backend).update(custom_trees)

        # Propagate option ids for non-selected backends
        for b in Store.loaded_backends():
            if b == backend:
                continue
            backend_trees = Store._custom_options[b]
            for (old_id, new_id) in id_mapping:
                tree = backend_trees.get(old_id, None)
                if tree is not None:
                    backend_trees[new_id] = tree
727300
def update_fw_params(self, rtr_id=-1, fw_type=-1):
        
        if rtr_id != -1:
            self.router_id = rtr_id
        if fw_type != -1:
            self.fw_type = fw_type
1299031
def update_settings(instance_id, settings)
      params = {
        :instance_id => instance_id
      }

      instance = Models::RegistryInstance[params] || Models::RegistryInstance.new(params)
      instance.settings = settings
      instance.save
    end
669895
def update_page_links(links) # :nodoc:
      ATTRIBUTES.each do |attr|
        send(:"#{attr}_page_uri=", links.send(:"#{attr}"))
        send(:"#{attr}_page=", parse_page_number(links.send(:"#{attr}")))
      end
    end
1353296
def update_urls(self, request, resource_name=None, ids=None):
        
        http_host = request.META.get('HTTP_HOST', None)

        if http_host is None:
            http_host = request.META['SERVER_NAME']
            if request.META['SERVER_PORT'] not in ('80', '443'):
                http_host = "{}:{}".format(
                    http_host, request.META['SERVER_PORT'])

        self.base_url = "{}://{}".format(
            request.META['wsgi.url_scheme'],
            http_host
        )
        self.api_url = "{}{}".format(self.base_url, request.path)
        self.api_url = self.api_url.rstrip("/")

        if ids is not None:
            self.api_url = self.api_url.rsplit("/", 1)[0]

        if resource_name is not None:
            self.api_url = self.api_url.rsplit("/", 1)[0]