Update a collection.

@param updateCollectionOptions the {@link UpdateCollectionOptions} containing the options for the call
@return a {@link ServiceCall} with a response type of {@link Collection}
969589
public ServiceCall<Collection> updateCollection(UpdateCollectionOptions updateCollectionOptions) {
    Validator.notNull(updateCollectionOptions, "updateCollectionOptions cannot be null");
    String[] pathSegments = { "v1/environments", "collections" };
    String[] pathParameters = { updateCollectionOptions.environmentId(), updateCollectionOptions.collectionId() };
    RequestBuilder builder = RequestBuilder.put(RequestBuilder.constructHttpUrl(getEndPoint(), pathSegments,
        pathParameters));
    builder.query("version", versionDate);
    Map<String, String> sdkHeaders = SdkCommon.getSdkHeaders("discovery", "v1", "updateCollection");
    for (Entry<String, String> header : sdkHeaders.entrySet()) {
      builder.header(header.getKey(), header.getValue());
    }
    builder.header("Accept", "application/json");
    final JsonObject contentJson = new JsonObject();
    if (updateCollectionOptions.name() != null) {
      contentJson.addProperty("name", updateCollectionOptions.name());
    }
    if (updateCollectionOptions.description() != null) {
      contentJson.addProperty("description", updateCollectionOptions.description());
    }
    if (updateCollectionOptions.configurationId() != null) {
      contentJson.addProperty("configuration_id", updateCollectionOptions.configurationId());
    }
    builder.bodyJson(contentJson);
    return createServiceCall(builder.build(), ResponseConverterUtils.getObject(Collection.class));
  }
518282
public static base_responses update(nitro_service client, policyhttpcallout resources[]) throws Exception {
		base_responses result = null;
		if (resources != null && resources.length > 0) {
			policyhttpcallout updateresources[] = new policyhttpcallout[resources.length];
			for (int i=0;i<resources.length;i++){
				updateresources[i] = new policyhttpcallout();
				updateresources[i].name = resources[i].name;
				updateresources[i].ipaddress = resources[i].ipaddress;
				updateresources[i].port = resources[i].port;
				updateresources[i].vserver = resources[i].vserver;
				updateresources[i].returntype = resources[i].returntype;
				updateresources[i].httpmethod = resources[i].httpmethod;
				updateresources[i].hostexpr = resources[i].hostexpr;
				updateresources[i].urlstemexpr = resources[i].urlstemexpr;
				updateresources[i].headers = resources[i].headers;
				updateresources[i].parameters = resources[i].parameters;
				updateresources[i].bodyexpr = resources[i].bodyexpr;
				updateresources[i].fullreqexpr = resources[i].fullreqexpr;
				updateresources[i].scheme = resources[i].scheme;
				updateresources[i].resultexpr = resources[i].resultexpr;
				updateresources[i].cacheforsecs = resources[i].cacheforsecs;
			}
			result = update_bulk_request(client, updateresources);
		}
		return result;
	}
669571
public function update(ExchangeRateCollection $collection)
    {
        $request = $this->initApiRequest(
            $this->account->getApiToken(Token::API_EXCHANGE_RATES),
            $this->account->getName(),
            $this->activeDomain
        );
        $request->setPath(ApiRequest::PATH_CURRENCY_EXCHANGE_RATE);
        $response = $request->post($collection);
        return self::checkResponse($request, $response);
    }
1210259
public function setOptions(Collection $options)
    {
        /** @var OptionInterface $option */
        foreach ($options as $option) {
            $this->addOption($option);
        }

        return $this;
    }
87136
@Override
	public Response updateContact(String CorpNum, ContactInfo contactInfo, String UserID) throws PopbillException {
		String postData = toJsonString(contactInfo);

		return httppost("/IDs", CorpNum, postData, UserID, Response.class);
	}
1001412
public function update ($collection_name, array $criteria, array $newObj, $options = array())
    {
        return $this->_call(
            'update', array(
                'collection_name' => $collection_name,
                'criteria'        => $criteria,
                'options'         => $options
            ), $newObj
        );
    }
617217
public void addCollection(Collection<? extends E> collection) {
		if (collection != null && !collection.isEmpty()) {
			this.collections.add(collection);
		}
	}
63596
public static base_responses update(nitro_service client, hanode resources[]) throws Exception {
		base_responses result = null;
		if (resources != null && resources.length > 0) {
			hanode updateresources[] = new hanode[resources.length];
			for (int i=0;i<resources.length;i++){
				updateresources[i] = new hanode();
				updateresources[i].id = resources[i].id;
				updateresources[i].hastatus = resources[i].hastatus;
				updateresources[i].hasync = resources[i].hasync;
				updateresources[i].haprop = resources[i].haprop;
				updateresources[i].hellointerval = resources[i].hellointerval;
				updateresources[i].deadinterval = resources[i].deadinterval;
				updateresources[i].failsafe = resources[i].failsafe;
				updateresources[i].maxflips = resources[i].maxflips;
				updateresources[i].maxfliptime = resources[i].maxfliptime;
				updateresources[i].syncvlan = resources[i].syncvlan;
			}
			result = update_bulk_request(client, updateresources);
		}
		return result;
	}
180472
protected function updateCollection($collection_id)
    {
        if (!$this->isError() && !$this->collection->update($collection_id, $this->getSubmitted())) {
            $this->errorAndExit($this->text('Unexpected result'));
        }
    }
1252036
public static base_responses update(nitro_service client, clusternodegroup resources[]) throws Exception {
		base_responses result = null;
		if (resources != null && resources.length > 0) {
			clusternodegroup updateresources[] = new clusternodegroup[resources.length];
			for (int i=0;i<resources.length;i++){
				updateresources[i] = new clusternodegroup();
				updateresources[i].name = resources[i].name;
				updateresources[i].strict = resources[i].strict;
			}
			result = update_bulk_request(client, updateresources);
		}
		return result;
	}
1325412
public function update(array $collection){
        foreach($collection as $key => $value){
            $this->collection[$key] = $value;
        }
        return $this;
    }
959167
public void updateProperties( Collection newProps )
    {
        _properties = new ArrayList();

        if ( newProps != null )
        {
            _properties.addAll( newProps );
        }
    }
822556
public static void updateCollections(PropertyStorage storage, Transport transport) {
        storage.getProperties().forEach(e -> {
            if (Collection.class.isAssignableFrom(e.getKey().getType())) {
                // found a collection in properties
                ((Collection) e.getValue()).forEach(i -> {
                    if (i instanceof FluentStyle) {
                        ((FluentStyle) i).setTransport(transport);
                    }
                });

            }

        });
    }
156325
@Indexable(type = IndexableType.REINDEX)
	@Override
	public CPOptionCategory updateCPOptionCategory(
		CPOptionCategory cpOptionCategory) {
		return cpOptionCategoryPersistence.update(cpOptionCategory);
	}
220162
protected function updateCollection($query, $update, $options)
    {
        return $this->getCollection()->replaceOne($query, $update, $options);
    }
1115814
function collectionUpdate (collection, result) {
	result._id = createID(result.pattern, result.language);
	return collection.insertOne(result)
		.catch((e) => {
			// May fail due to concurrent update on the same value.
			log(`collectionUpdate: error: ${e}`);
			return Promise.resolve(PATTERN_INVALID);
		});
}
429993
public function setCollectionOptions(array $collectionOptions)
    {
        if ($this->nested) {
            throw new LogicException(
                sprintf(
                    'Collection options cannot be set for nested document class "%s".',
                    $this->documentClass
                )
            );
        }

        $this->collectionOptions = $collectionOptions;

        return $this;
    }