Adds the given metadata dict to the existing metadata for the specified
        webhook.
503718
def update_webhook_metadata(self, webhook, metadata):
        
        return self.manager.update_webhook_metadata(self.scaling_group, self,
                webhook, metadata)
616499
def add_value(self, value, metadata=""):
        
        data = {
            'value': value,
            'metadata': metadata
        }

        return self.post('createValue', data)
219296
public Object putNodeMetaData(Object key, Object value) {
        if (key == null) throw new GroovyBugError("Tried to set meta data with null key on " + this + ".");
        if (metaDataMap == null) {
            metaDataMap = new ListHashMap();
        }
        return metaDataMap.put(key, value);
    }
493452
def add_key_value(self, key, value):
        
        key = self._metadata_map.get(key, key)
        if key in ['dateAdded', 'lastModified']:
            self._data[key] = self._utils.format_datetime(value, date_format='%Y-%m-%dT%H:%M:%SZ')
        elif key == 'confidence':
            self._data[key] = int(value)
        elif key == 'rating':
            self._data[key] = float(value)
        elif key == 'unique_id':
            self._unique_id = quote_plus(value)
        else:
            self._data[key] = value
951605
def _set_metadata(self, value):
        '''
        
        '''
        if value is None:
            setattr(self, '_PMMail__metadata', {})
        elif isinstance(value, dict):
            for k, v in value.items():
                if (not isinstance(k, str) and not isinstance(k, int)) \
                    or (not isinstance(v, str) and not isinstance(v, int)):
                    raise TypeError('Metadata keys and values can only be strings or integers')
            setattr(self, '_PMMail__metadata', value)
        else:
            raise TypeError('Metadata must be a dictionary of key-value pairs')
227072
def metadata_add_endpoints(self):
        
        metadata = load_mpe_service_metadata(self.args.metadata_file)
        group_name = metadata.get_group_name_nonetrick(self.args.group_name)
        for endpoint in self.args.endpoints:
            metadata.add_endpoint(group_name, endpoint)
        metadata.save_pretty(self.args.metadata_file)
1269792
def update_metadata(self, loadbalancer, metadata, node=None):
        
        # Get the existing metadata
        md = self.get_metadata(loadbalancer, raw=True)
        id_lookup = dict([(itm["key"], itm["id"]) for itm in md])
        metadata_list = []
        # Updates must be done individually
        for key, val in metadata.items():
            try:
                meta_id = id_lookup[key]
                if node:
                    uri = "/loadbalancers/%s/nodes/%s/metadata/%s" % (
                            utils.get_id(loadbalancer), utils.get_id(node),
                            meta_id)
                else:
                    uri = "/loadbalancers/%s/metadata" % utils.get_id(loadbalancer)
                req_body = {"meta": {"value": val}}
                resp, body = self.api.method_put(uri, body=req_body)
            except KeyError:
                # Not an existing key; add to metadata_list
                metadata_list.append({"key": key, "value": val})
        if metadata_list:
            # New items; POST them
            if node:
                uri = "/loadbalancers/%s/nodes/%s/metadata" % (
                        utils.get_id(loadbalancer), utils.get_id(node))
            else:
                uri = "/loadbalancers/%s/metadata" % utils.get_id(loadbalancer)
            req_body = {"metadata": metadata_list}
            resp, body = self.api.method_post(uri, body=req_body)
305134
def add(self, obj, metadata=None, update=False):
        
        if (obj not in self) or update:
            self[obj.id] = Object.fromdict(
                obj.id,
                dict(
                    metadata=obj.metadata.read() if metadata is None else metadata,
                    bitstreams=[bs._properties for bs in obj.bitstreams]))
            time.sleep(0.1)
            return self.objects[obj.id]
165099
def add_key(self, key, metadata=""):
        
        data = {
            'key': key,
            'metadata': metadata
        }

        return self.post('createKey', data)
1091027
def replace_meta(self, name, content=None, meta_key=None):
        '''
        '''
        children = self.meta._children
        if not content:     # small optimazation
            children = tuple(children)
        meta_key = meta_key or 'name'
        for child in children:
            if child.attr(meta_key) == name:
                if content:
                    child.attr('content', content)
                else:
                    self.meta._children.remove(child)
                return
        if content:
            self.add_meta(**{meta_key: name, 'content': content})
343699
private function addCommonMetaData()
    {
        $this->bugsnag->registerCallback(function ($report) {
            $report->addMetaData([
                'META DATA' => [
                    'store_url' => $this->storeManager->getStore()->getBaseUrl(
                        \Magento\Framework\UrlInterface::URL_TYPE_WEB
                    )
                ]
            ]);
        });
    }
1123327
def add_entity_meta(self, datastream, options, data):
        
        url = '/datastream/' + str(datastream) + '/entityMeta'
        response = self.http.post(url, data)
        entityMetaList = []
        for entityMeta in response:
            entityMetaList.append(Schemas.EntityMeta(entityMeta=entityMeta))
        return entityMetaList
1092128
def add(self, key, content, **metadata):
        
        self.members.add(key)
        document_hash = self._get_hash(key)
        document_hash.update(content=content, **metadata)

        for word, score in self.tokenizer.tokenize(content).items():
            word_key = self.get_key(word)
            word_key[key] = -score
915582
def _update_meta(self):
        
        for v in ["filename", "location", "prefix"]:
            if "meta" not in self:
                self["meta"] = {}
            self["meta"][v] = self[v]
            del self[v]
602727
def update_webhook(self, scaling_group, policy, webhook, name=None,
            metadata=None):
        
        return self._manager.update_webhook(scaling_group=scaling_group,
                policy=policy, webhook=webhook, name=name, metadata=metadata)
446176
def _merge_meta(self, encoded_meta, meta):
        
        new_meta = None

        if meta:
            _meta = self._decode_meta(encoded_meta)
            for key, value in six.iteritems(meta):
                if value is None:
                    _meta.pop(key, None)
                else:
                    _meta[key] = value
            new_meta = self._encode_meta(_meta)

        return new_meta
508725
private void updateRequestMetadata() {
        // Take event level metadata, merge with top level metadata
        // event level metadata takes precedence
        try {
            JSONObject metadata = new JSONObject();
            Iterator<String> i = prefHelper_.getRequestMetadata().keys();
            while (i.hasNext()) {
                String k = i.next();
                metadata.put(k, prefHelper_.getRequestMetadata().get(k));
            }
            JSONObject originalMetadata = params_.optJSONObject(Defines.Jsonkey.Metadata.getKey());
            if (originalMetadata != null) {
                Iterator<String> postIter = originalMetadata.keys();
                while (postIter.hasNext()) {
                    String key = postIter.next();
                    // override keys from above
                    metadata.put(key, originalMetadata.get(key));
                }
            }
            // Install metadata need to be send only with Install request
            if ((this instanceof ServerRequestRegisterInstall) && prefHelper_.getInstallMetadata().length() > 0) {
                params_.putOpt(Defines.Jsonkey.InstallMetadata.getKey(), prefHelper_.getInstallMetadata());
            }
            params_.put(Defines.Jsonkey.Metadata.getKey(), metadata);
        } catch (JSONException e) {
           PrefHelper.Debug("Could not merge metadata, ignoring user metadata.");
        }
    }