Sets a request attribute.

@param string $name  Attribute name
@param mixed  $value Attribute value
342494
public function setAttribute(string $name, $value): void
	{
		Arr::set($this->attributes, $name, $value);
	}
987062
public function set($name, $value)
    {
        if (! is_array($value)) {
            $value = ['value' => (string) $value];
        }
        $this->responseCookies[$name] = array_replace($this->defaults, $value);
    }
883564
final protected function setAttribute($name, $value)
    {
        if ($value !== null && $this->hasAttributeValueFactory($name)) {
            $this->internalCache[$name] = $this->createAttributeValue($name, $value);

            if ($this->internalCache[$name] instanceof JsonSerializable) {
                $value = $this->internalCache[$name]->jsonSerialize();
            } elseif (is_array($this->internalCache[$name])) {
                $value = array_map(
                    function ($value) {
                        if ($value instanceof JsonSerializable) {
                            $value = $value->jsonSerialize();
                        }

                        return $value;
                    },
                    $this->internalCache[$name]
                );
            } else {
                $value = $this->internalCache[$name];
            }
        }

        $this->data[$name] = $value;

        return $this;
    }
1215362
public function attrSet($name, $value)
    {
        $idx = $this->attrIndex($name);
        $attrData = [ $name, $value ];

        if ($idx < 0) {
            $this->attrPush($attrData);
        } else {
            $this->attrs[$idx] = $attrData;
        }
    }
961670
public function writeAttribute($name, $value) {
        $method = 'set' . ucfirst($name);
        if(method_exists($this, $method)) {
            $this->$method($value);
        } else {
            parent::writeAttribute($name, $value);
        }
    }
551840
public function setAttribute($name, $value = null)
    {
        $this->getAttributes()->set($name, $value);
        return $this;
    }
373497
public function setRequestHeader($name, $value) {
    $header = array();
    $header[$name] = $value;
    //TODO: as a limitation of the driver it self, we will send permanent for the moment
    $this->browser->addHeader($header, true);
  }
1228487
public function setAttribute( $name, $value )
    {
        if ( isset( $this->dynamicAttributeFunctions[$name] ) )
        {
            switch ( $name )
            {
                case 'valid_nodes':
                    $this->dynamicAttributeFunctions[$name] = $value;
                    break;
                default:
                break;
            }
        }
        else
        {
            $this->attributes[$name] = $value;
        }
    }
33208
public function & SetParam ($name = '', $value = '') {
		/** @var $this \MvcCore\Request */
		if ($this->params === NULL) $this->initParams();
		$this->params[$name] = $value;
		return $this;
	}
684628
private function set(string $name, $value):void{
		$method = 'magic_set_'.$name;

		if(\method_exists($this, $method)){
			$this->$method($value);
		}

	}
590008
protected function setParam($name, $value) {
        $params = $this->getParams();
        $params->$name = $value;
        $this->setParams($params);
    }
1328242
private function set($name, $value)
	{
		if (property_exists($this, $name))
		{
			$this->$name = $value;
			$this->attributes[$name] = $value;
			return true;
		}

		return false;
	}
602008
public function setAttribute(string $name, $value)
    {
        if (array_key_exists($name, $this->attributes)) {
            throw new AttributeOverrideException($this, $name);
        }

        $this->attributes[$name] = $value;
    }
891043
public function setAttribute($name, $value = null)
    {
        $name = strtolower($name);
        if (is_null($value)) {
            $value = $name;
        }
        if (in_array($name, $this->watchedAttributes)) {
            $this->onAttributeChange($name, $value);
        } else {
            $this->attributes[$name] = (string)$value;
        }
        return $this;
    }
1271243
public function setParam($name, $value): void
    {
        if (\is_array($this->params)) {
            // Arrays or objects implementing array access
            $this->params[$name] = $value;
        } else {
            // Objects
            $this->params->{$name} = $value;
        }
    }
1247433
public function attribute(string $name, string $value = null) : object
    {
        $this->attributes[$name] = $value;
        return $this;
    }
372302
public function addAttribute($name, $value)
    {
        $nameUtf8 = $this->_toUTF8($name);
        $valueUtf8 = htmlspecialchars($this->_toUTF8($value), ENT_COMPAT, "UTF-8");
        if (($valueUtf8 === "") && (version_compare("5.2.2", PHP_VERSION, ">"))) {
            $this->_SimpleXmlElement->addAttribute($nameUtf8, "\0"); // Fixing bug #41175 (addAttribute() fails to add an attribute with an empty value)
        } else {
            $this->_SimpleXmlElement->addAttribute($nameUtf8, $valueUtf8);
        }
    }