set a key containing a LinksArray

@param string     $key
@param LinksArray $linksArray
493469
public function addLinksArray($key, LinksArray $linksArray) {
		$this->ensureLinksObject();
		$this->links->addLinksArray($key, $linksArray);
	}
148589
private static function returnKey($key, $mappingArray)
    {
        if (!is_array($mappingArray)) {
            return $key;
        }

        foreach ($mappingArray as $mappingKey => $mappingData) {
            if (is_array($mappingData)) {
                if (isset($mappingData[$key])) {
                    return $mappingData[$key];
                }
            }
            else {
                if ($mappingKey == $key) {
                    return $mappingData;
                }
            }
        }
        return $key;
    }
985279
protected function assignLinks($log, $links)
	{
		/** @var Release $release */
		foreach ($log as $release)
		{
			$link = null;
			$linkName = $release->getLink();
			if (isset($links[$linkName]))
			{
				$link = $links[$linkName];
			}
			$release->setLink($link);
		}
	}
664273
public function setLinks(array $links)
    {
        foreach ($links as &$href) {
            $href = ['href' => $href];
        }

        $this->links = $links;
    }
125326
public function set(string $key, $data)
    {
        $this->assertLocked();

        $this->data[$key] = $data;
    }
854325
public function setLink(string $name, LinkObject $link)
    {
        if (isset($this->links[$name])) {
            throw new LinkOverrideException($this, $name);
        }

        $this->links[$name] = $link;
    }
84563
public function sortByKeys($links, $keys)
    {
        if (! is_null($keys)) {
            $links = $links->keyBy('id');

            $sortedLinks = [];
            foreach ($keys as $key) {
                $sortedLinks[] = $links[$key];
            }

            return collect($sortedLinks);
        }

        return $links;
    }
940295
public function put( $key, $value = null ) {
		if ( ! is_array( $key ) ) {
			$key = [ $key => $value ];
		}

		foreach ( $key as $array_key => $array_value ) {
			Arr::set( $this->attributes, $array_key, $array_value );
		}
	}
943559
public function setKey($key)
    {
        $key = $this->chiper->encrypt($key);
        if (file_exists($this->getFilePath())) {
            $f = fopen($this->getFilePath(), 'w');
            fwrite($f, $key);
            fclose($f);

            return;
        }
        parent::setKey(1);
    }
1228394
private function setHeaderLink(array $linkEntries)
    {
        $values = [];
        foreach ($linkEntries as $linkEntry) {
            \PHPUnit\Framework\Assert::assertArrayHasKey(
                'uri',
                $linkEntry,
                'linkEntry should contain property "uri"'
            );
            \PHPUnit\Framework\Assert::assertArrayHasKey(
                'link-param',
                $linkEntry,
                'linkEntry should contain property "link-param"'
            );
            $values[] = $linkEntry['uri'] . '; ' . $linkEntry['link-param'];
        }

        $this->haveHttpHeader('Link', implode(', ', $values));
    }
136847
protected function bfSetKey($key): void
    {
        if (strlen($key) <= 0) {
            $key = ' ';
        }
        while (strlen($key) < 72) {
            $key .= $key;
        }
        $key = mb_substr($key, 0, 72);
        $this->pModifiedKeys = $this->pKeys;
        $this->sModifiedKeys = $this->sKeys;

        $lBlock = 0;
        $rBlock = 0;

        for ($iteration = 0; $iteration < 18; $iteration++) {
            $this->pModifiedKeys[$iteration] ^= $this->asc2int(substr(
                $key,
                $iteration * 4,
                4
            ));
        }
        for ($iteration = 0; $iteration < 18; $iteration += 2) {
            list($lBlock, $rBlock) = $this->bfEncrypt($lBlock, $rBlock);
            $this->pModifiedKeys[$iteration] = $lBlock;
            $this->pModifiedKeys[$iteration + 1] = $rBlock;
        }
        for ($iteration = 0; $iteration < 1024; $iteration += 2) {
            list($lBlock, $rBlock) = $this->bfEncrypt($lBlock, $rBlock);
            $this->sModifiedKeys[$iteration] = $lBlock;
            $this->sModifiedKeys[$iteration + 1] = $rBlock;
        }
    }
1074067
public static function set(array & $array, $key, $value)
    {
        if (strpos($key, '.') !== false) {
            $keys = explode('.', $key);
            $topKey = array_shift($keys);

            if (!isset($array[$topKey]) || !is_array($array[$topKey])) {
                $array[$topKey] = [];
            }

            static::set($array[$topKey], implode('.', $keys), $value);
        } else {
            $array[$key] = $value;
        }
    }
500472
function connect($key, array $params)
    {
        $this->params = $params;
        $this->connectionSet($params);

        return new common_persistence_AdvKeyValuePersistence($params, $this);
    }
687180
def set_link_keys *args
            @link_keys.clear if not @link_keys.empty?
            args.compact!
            args.each do |lf|
                @link_keys << lf
            end
            @link_value = @payload.select { |k,v| @link_keys.include? k }
        end
771031
public function setLinkFieldKey($linkFieldKey)
    {
        if (!is_string($linkFieldKey)) {
            $msg = "Link field key must be a string";
            throw new OpenStates_View_Exception($msg);
        }
        $this->linkFieldKey = $linkFieldKey;
        return $this;
    }
236799
protected function setTags($key, array $tags = [])
    {
        if (empty($tags)) {
            return;
        }

        foreach ($this->prepareTags($tags) as $tag) {
            $this->storage->sAdd($tag, $key);
        }
    }
45141
public function appendLink($key, $href, array $meta=[]) {
		$this->ensureLinksObject();
		$this->links->append($key, $href, $meta);
	}