Set the value in the event.

@param GetGroupHeaderEvent $event The event being emitted.
@param string              $value The value returned by the callback.

@return void
422595
public function update($event, $value)
    {
        if (null === $value) {
            return;
        }

        $event->setValue($value);
        $event->stopPropagation();
    }
784720
public function setValue($value)
    {
        if ($this->value instanceof Binding && !($value instanceof Binding)) {
            $this->value->setValue($value);
        } else {
            $this->value = $value;
        }
    }
486873
public function setValue($value)
    {
        if (is_scalar($value) or is_null($value)) {
            return;
        }
        foreach ($value as $name => $val) {
            if ($field = $this[$name]) {
                $field->getElement()->setValue($val);
            }
        }
    }
760025
public function setValue($value)
    {
        $this->clear();

        if (!is_array($value)) {
            $value = [$value];
        }

        foreach ($value as $argument) {
            $this[] = $argument;
        }
    }
944396
public function setConfirmation($value)
    {
        $cAttribute = $this->confirmationAttribute;
        if (!$cAttribute || empty($cAttribute)) {
            return;
        }
        $this->$cAttribute = $value;
        $this->trigger(static::$eventConfirmationChanged);
    }
1340685
public function setHeader(string $name, $value)
    {
        parent::setHeader($name, $value);

        if (\stripos($name, "set-cookie") === 0) {
            $this->setCookiesFromHeaders();
        }
    }
843567
public static function event($value): void
    {
        if (false === self::message($value)) {
            throw new Exception\InvalidEvent($value);
        }
    }
1186357
public function set($name, $value)
    {
        if ($this->readonly) {
            throw new ReadonlyException();
        }

        $this->headers[$name] = $value;
    }
757941
public function setRawValue( $value )
	{
		if ( is_null( $value ) )
			$this->_value = CoreFuncs::$False;
		else
			$this->_value = $value;

		$this->_xmlType = null;
	}
1261506
protected function setHeader(string $name, string $value)
    {
        $normalized = $this->normalizeHeaderKey($name);
        $this->headerNames[$normalized] = $name;
        $this->headers[$name] = $this->trimHeaderValues([$value]);
    }
553207
public function setValue($value) {
		if(is_string($value) && $this->getOption('trim'))
			$value = trim($value);

		$this->value = $value;
	}
98001
protected function setValue($value, string $type)
    {
        $this->value = $type !== self::TYPE_CALL
            ? $this->validateValue($value)
            : array_map(function ($value) {
                return $this->validateValue($value);
            }, $value);
    }
1321965
public function setCaption($value) {
		if (JString::startswith($value, "-")) {
			$this->class="dropdown-header";
			$this->role="presentation";
			$this->_template='<li id="%identifier%" class="%class%" role="%role%">%content%</li>';
			if ($value==="-") {
				$this->class="divider";
			}
			$value=substr($value, 1);
		}
		$this->content=$value;
		return $this;
	}
909682
public function setValue(string $value) : RadioGroup
    {
        foreach ($this->radios as $radioButton) {
            $radioButton->setChecked($radioButton->getValue() === $value);
        }

        return $this;
    }
317736
function setValue($value)
    {
        $this->setChecked(isset($this->_values[1]) && $value == $this->_values[1]);
        $this->_currentValue = $value;
    }
1023960
protected function setHeader($name, $value)
    {
        if (! is_array($value)) {
            $value = [$value];
        }
        $this->headers[$name] = $value;
        $this->headerKeys[strtolower($name)] = $name;
    }
1236641
public function setTargetGroup(GetResponseEvent $event)
    {
        $request = $event->getRequest();

        if ($targetGroupId = $request->headers->get($this->targetGroupHeader)) {
            $this->targetGroupStore->setTargetGroupId($targetGroupId);
        } elseif ($targetGroupId = $request->cookies->get($this->targetGroupCookie)) {
            $visitorSession = $request->cookies->get($this->visitorSessionCookie);
            if ($visitorSession) {
                $this->targetGroupStore->setTargetGroupId($targetGroupId);

                return;
            }

            $targetGroup = $this->targetGroupEvaluator->evaluate(
                TargetGroupRuleInterface::FREQUENCY_SESSION,
                $this->targetGroupRepository->find($targetGroupId)
            );

            if ($targetGroup) {
                $this->targetGroupStore->updateTargetGroupId($targetGroup->getId());
            }
        } elseif ($request->getPathInfo() !== $this->targetGroupUrl) {
            // this should not happen on the endpoint for the cache, because it is set there manually as a header
            $targetGroup = $this->targetGroupEvaluator->evaluate();

            $targetGroupId = 0;
            if ($targetGroup) {
                $targetGroupId = $targetGroup->getId();
            }

            $this->targetGroupStore->updateTargetGroupId($targetGroupId);
        }
    }