@param string $name
@param        $value

@return ContextInterface
505388
public function set(string $name, $value): ContextInterface
    {
        $this->bagContext->offsetSet($name, $value);

        return $this;
    }
366508
public function get($name, $value)
    {
        if ($this->has($name)) {
            return new self::$classMap[$name]($value);
        }

        return new Custom($name, $value);
    }
1217330
public function header($name, $value = null)
    {

        if ($value === null) {
            $this->headers[] = $name;
        } else {
            $this->headers[] = $this->headerString($name, $value);
        }

        return $this;
    }
1168212
public function setHeader($name, $value)
    {
        $this->getResponse()->headers->set($name, $value);

        return $this;
    }
581218
final public function set(string $name, $value)
    {
        $this->container->setParameter($name, static::processValue($value, true));

        return $this;
    }
147768
public function set($name, $value)
    {
        Config::modify()->set($this->class, $name, $value);
        return $this;
    }
1361771
public function setHeader($name, $value)
    {
        $name = trim($name);
        $this->headers[$name] = trim($value);

        return $this;
    }
379082
public function withHeader($name, $value)
    {
        $request = clone $this;
        $request->headers->set($name, $value);

        return $request;
    }
948773
public static function set($name, $value)
    {
        $coID = Coroutine::getuid();
        if(!isset(static::$context[$coID]))
        {
            throw new \RuntimeException('set context data failed, current context is not found');
        }
        static::$context[$coID][$name] = $value;
    }
1299950
protected function withHeader($name, $value)
    {
        $this->headers[ strtolower($name) ] = is_array($value)
            ? $value
            : [ $value ];

        return $this;
    }
40249
public function headerLine($name, $value)
    {
        if (stripos($name, 'X-') !== false) {
            return null;
        }

        return parent::headerLine($name, $value);
    }
39992
public function header(string $name, $value): HttpRequest
    {
        if (!array_key_exists($name, $this->headers)) {
            $this->headers[$name] = array();
        }
        $this->headers[$name][] = $value;

        return $this;
    }
634870
protected function setSetting($name, $value)
    {
        $args = $this->getArgument("settings");
        if (is_null($args)) {
            $args = array();
        }
        $args[$name] = $value;
        return $this->setArgument("settings", $args);
    }
664652
public function addHeader( $name, $value )
	{
		$hs = $this->object->getHeaders();
		$hs->addTextHeader( $name, $value );
		return $this;
	}
1344070
final public function withHeader($name, $value): self
    {
        $message = clone $this;

        //Make sure to remove the current header with the same
        //name to avoid casing-duplication (location, Location, LOCATION)
        if ($message->hasHeader($name)) {
            $message = $message->withoutHeader($name);
        }

        $message->addHeaders([$name => $value]);
        return $message;
    }
651910
public function implicit(string $name, $value): self
    {
        $this->defaults[$name] = $value;
        return $this;
    }
231076
public function setValidationConfig(string $name, $value): NodeInterface
    {
        $this->setMetadataAttr('validations.'.$name, $value);

        return $this;
    }