Add variable(s) to replacement list
it will automatically format scalar types and arrays,
so they text representation will be inserted

@param $name  array|string
@param $value null|string|array
@return $this
5154
public function set($name, $value = null)
    {
        if (is_array($name)) {
            foreach ($name as $innerName => $innerValue) {
                $this->replace($innerName, $this->formatValue($innerValue));
            }
        } else {
            $this->replace($name, $this->formatValue($value));
        }

        // return is for chaining
        return $this;
    }
1073
public function set($name, $value = null)
    {
        if (is_array($name)) {
            $this->parameters = array_replace($this->parameters, $name);
        } else {
            $this->parameters[trim(strtolower($name))] = is_string($value) ? trim($value) : $value;
        }
    }
1165235
public function setContext($name, $value = null)
    {
        if (is_array($name)) {
            $this->context = $name + $this->context;
        } else {
            $this->context[$name] = $value;
        }
        return $this;
    }
1281562
public function add(string $name, $value)
    {
        if (is_array($name)) {
            foreach ($name as $key => $value) {
                $this->data[$key] = $value;
            }

            return $this;
        }

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

        return $this;
    }
286511
public function addAttr($name, $value)
    {
        if (!in_array($name, $this->attributes)) {
            $this->attributes[$name] = $value;
        }
        return $this;
    }
843874
public function set($name, $value): self
    {
        if (!\is_array($value)) {
            $value = ['value' => (string)$value];
        }

        parent::set($name, \array_replace($this->defaults, $value));

        return $this;
    }
593475
public static function set($name,$value=null)
    {
        if(is_array($name)){
            self::$config=array_merge(self::$config,$name);
            return;
        }
        if(strstr($name,'.')===false){
            self::$config[$name]=$value;
        }else{
            list($l,$r)=explode('.',$name);
            self::$config[$l][$r]=$value;
        }
    }
1111065
function setParameter($name, $value)
    {
        $this->name = $name;
        $this->value = $value;

        return $this;
    }
318151
public function addArgument($name, $value)
    {
        if (!isset($this->arguments[$name])) {
            $this->arguments[$name] = $value;
        }

        return $this;
    }
221739
public function append($name, $value)
    {
        if (is_array($this->_data[$name])) {
            $this->_data[$name][] = $value;
        } else {
            $this->_data[$name] .= $value;
        }

        return $this;
    }
220400
public function add(string $name, $value): self
    {
        $this->headers[$name] = $value;
        return $this;
    }
357283
public function setRaw($name, $value = null)
    {
        if (is_array($name)) {
            foreach ($name as $innerName => $innerValue) {
                $this->replace($innerName, $innerValue);
            }
        } else {
            $this->replace($name, $value);
        }

        // return is for chaining
        return $this;
    }
282209
protected function setData($name, $value = null)
    {
        if (is_array($name)) {
            $this->data = array_merge($this->data, $name);
        }
        elseif (is_string($name)) {
            $this->data[$name] = $value;
        }

        return $this;
    }
316638
public function add($name, $value = null, array $params = [])
    {
        if (is_array($value)) {
            $params = $value;
            if (isset($params['value'])) {
                $value = $params['value'];
                unset($params['value']);
            } else {
                $value = '';
            }
        }
    
        $params = array_merge($this->defaults, $params);
        $this->jar[$name] = new Cookie($name, $value, $params['expires'], $params['path'], $params['domain'], $params['secure'], $params['httponly'], $params['raw']);
        return $this;
    }
80262
public function set( string $name, $value )
	{
		if( $name === "default" )
		{
			if( is_scalar($value) )
				$this->default = $value;
		}
		else if( $name !== "name" && isset($this->{$name}) && gettype($this->{$name}) === gettype($value) )
		{
			$this->{$name} = $value;
		}
		return $this;
	}
628685
public function set($name, $value = null): self
    {
        if (!is_array($name)) {
            $name = [$name => $value];
        }

        foreach ($name as $property => $value) {
            $this->_data[$property] = $value;
        }

        return $this;
    }
566802
public function addParserBody(string $name, $value)
    {
        if (is_array($this->parsedBody)) {
            $clone = clone $this;
            $clone->parsedBody[$name] = $value;

            return $clone;
        }
        return $this;
    }