bulk update a bunch of Items in one API hit
 takes a list of <tt>Item::ItemId</tt>s, or a list of <tt>Item::Item</tt>,
 or a <tt>Folder::FindResult</tt> and applies the same set of updates to each of them
174162
def update_item(message_ids, opts={})
      opts = check_opts(UPDATE_ITEM_OPTS, opts)
      message_ids = message_ids.result if message_ids.is_a?(Folder::FindResult)

      updates = [*opts[:updates]].compact
      raise "no updates!" if updates.empty?
      r = with_error_check(self, :update_item_response, :response_messages, :update_item_response_message) do
        self.savon_client.request(:wsdl, "UpdateItem", 
                                  :ConflictResolution=>opts[:conflict_resolution],
                                  :MessageDisposition=>opts[:message_disposition]) do
          http.headers["SOAPAction"] = "\"#{SCHEMA_MESSAGES}/UpdateItem\"" # required by EWS 2007
          soap.namespaces["xmlns:t"]=SCHEMA_TYPES
          
          xml = Builder::XmlMarkup.new
          
          xml.wsdl :ItemChanges do
            message_ids.each do |mid|
              mid = mid.item_id if mid.is_a?(Item::Item)
              xml.t :ItemChange do
                xml << mid.to_xml(opts[:ignore_change_keys])
                xml.t :Updates do
                  updates.each do |update|
                    xml << update.to_xml
                  end
                end
              end
            end
          end
          
          soap.body = xml.target!
        end
      end
      r
    end
996177
def automations_update_many(self, data, **kwargs):
        ""
        api_path = "/api/v2/automations/update_many.json"
        return self.call(api_path, method="PUT", data=data, **kwargs)
683931
def _update_items(self, items):
        
        self.items = items
        self.map = {item: idx for (idx, item) in enumerate(items)}
131914
def bulk_save(self, action_list, **kwargs):
        '''  '''

        lg = logging.getLogger("%s.%s" % (self.ln, inspect.stack()[0][3]))
        lg.setLevel(self.log_level)
        err_log = logging.getLogger("index.errors")
        es = self.es
        es_index = get2(kwargs, "es_index", self.es_index)
        reset_index = kwargs.get("reset_index",self.reset_index)
        doc_type = kwargs.get("doc_type", self.doc_type)

        lg.info("Sending %s items to Elasticsearch",len(action_list))
        # bulk_stream = helpers.streaming_bulk(es,
        result = helpers.bulk(es,
                              action_list,
                              chunk_size=400,
                              raise_on_error=False)
        lg.info("FINISHED sending to Elasticsearch")
        if result[1]:
            lg.info("Formating Error results")
            # action_keys = {item['_id']:i for i, item in enumerate(action_list)}
            new_result = []
            for item in result[1][:5]:
                for action_item in action_list:
                    if action_item['_id'] == item[list(item)[0]]['_id']:
                        new_result.append((item, action_item,))
                        break
            err_log.info("Results for batch '%s'\n(%s,\n%s\n%s)",
                         kwargs.get('batch', "No Batch Number provided"),
                         result[0],
                         json.dumps(new_result, indent=4),
                         json.dumps(result[1]))
            del new_result
            lg.info("Finished Error logging")
        # for success, result in bulk_stream:
        #     lg.debug("\nsuccess: %s \nresult:\n%s", success, pp.pformat(result))
        return result
1309842
def post_bulk_collection(collection, options={})
      raise ArgumentError, "Array expected as :collection, got #{collection.inspect}" \
            unless collection.is_a?(Array)
      bulk_string = ''
      collection.each do |d|
        bulk_string << build_bulk_string(d, options)
      end
      post_bulk_string(:bulk_string => bulk_string) unless bulk_string.empty?
    end
57596
function updateExistingItems(groupUi) {
    let itemUi = groupUi.firstElementChild
    while (itemUi) {
      updateItem(itemUi)
      itemUi = itemUi.nextElementSibling
    }
  }
205029
function Routes(opts, items) {
	var self = this;
	opts = opts || {};
	items = items || [];
	debug.assert(self).is('object');
	debug.assert(opts).is('object');
	debug.assert(items).is('array');

	opts = copy(opts);
	self.file = opts.file;
	self.items = copy(items);
	self.changed = opts.changed || false;

	debug.assert(self.items).is('array');

	// Make an object (hash map) as an index for searching targets faster (path + method)
	self.targets = {};
	load_targets(self);

	debug.assert(self.file).is('string');
	debug.assert(self.targets).is('object');
}
1072448
def refresh_items(self):
        
        items = []
        if self.condition:
            for nodes, key, f_locals in self.pattern_nodes:
                with new_scope(key, f_locals):
                    for node in nodes:
                        child = node(None)
                        if isinstance(child, list):
                            items.extend(child)
                        else:
                            items.append(child)

        for old in self.items:
            if not old.is_destroyed:
                old.destroy()

        #: Insert items into THIS node, NOT the PARENT
        #if len(items) > 0:
        #    self.parent.insert_children(self, items)
        self.items = items
1005365
@MainThread
    public void update(@NonNull List<T> newItems, @NonNull DiffUtil.DiffResult diffResult) {
        synchronized (LIST_LOCK) {
            list = newItems;
        }
        diffResult.dispatchUpdatesTo(listCallback);
    }
243935
def get_bulk_modify(self, value):
        """"""
        if self.multiselect:
            value = value or []
            return [self.cast_to_bulk_modify(child) for child in value]

        return self.cast_to_bulk_modify(value)
753134
function (items) {
        var self = this;

        // Force single item into array
        if (!Tools.isArray(items)) {
          if (items instanceof Collection) {
            self.add(items.toArray());
          } else {
            push.call(self, items);
          }
        } else {
          push.apply(self, items);
        }

        return self;
      }
635412
def update(self, id, **dict):
        ''''''
        if not self._item_path:
            raise AttributeError('update is not available for %s' % self._item_name)
        target = (self._update_path or self._item_path) % id
        payload = json.dumps({self._item_type:dict})
        self._redmine.put(target, payload)
        return None
200191
def _put_many(self, items):
        ''' 
        '''
        for item in items:
            if not isinstance(item, self._item_class):
                raise RuntimeError('Items mismatch for %s and %s' % (self._item_class, type(item)))
            self._put_one(item)
377983
def lookup_bulk(self, ResponseGroup="Large", **kwargs):
        
        response = self.api.ItemLookup(ResponseGroup=ResponseGroup, **kwargs)
        root = objectify.fromstring(response)
        if not hasattr(root.Items, 'Item'):
            return []
        return list(
            AmazonProduct(
                item,
                self.aws_associate_tag,
                self,
                region=self.region) for item in root.Items.Item
        )
482638
def move_bulk(self, from_statuses, to_status):
        

        for status in from_statuses:
            from_status_items = self.__get_var("items_" + status)
            self.__set_var("items_" + status, OrderedDict())

            to_status_items = self.__get_var("items_" + to_status)
            to_status_items.update(from_status_items)
158844
def update(self, item_id, attributes, silent=False, hook=True):
        
        if not isinstance(attributes, dict):
            raise TypeError('Must be of type dict')
        attributes = json.dumps(attributes)
        return self.transport.PUT(body=attributes,
                                  type='application/json',
                                  url='/item/%d%s' % (item_id, self.get_options(silent=silent,
                                                                                hook=hook)))
813558
function getItemsFromList(list, itemsToGet) {
    var result = [];

    _.each(list, function (item) {
        for (var i = 0; i < itemsToGet.length; i++) {
            if (item.indexOf(itemsToGet[i]) === 0) {
                result.push(item);
            }
        }
    });

    return result;
}