It adds the header to the stack.
@param string $sHeader The page header.
@return self.
@throws \core\Exception It throws if passed header was already added earlier.
760576
public function add($sHeader)
    {
        foreach ($this->headerList as $sTmp) {
            if ($sTmp == $sHeader) {
                throw new Exception("The '{$sHeader}' header has already been added.");
            }
        }
        $this->headerList[] = $sHeader;
        return self::$instance;
    }
91329
function add($header)
    {
        // convert to object form
        if (is_string($header))
            $header = HeaderField::fromString($header);

        $this->_headers[] = $header;
        return $this;
    }
570389
public function withHeader($header, $value)
    {
        if ($this->complete) {
            return $this;
        }

        $new = $this->psrResponse->withHeader($header, $value);
        return new self($new);
    }
668093
public function withAddedHeader($name, $value) : self
    {
        $new = clone $this;

        return $new->setResponse($this->response->withAddedHeader($name, $value));
    }
760192
function sendHeaders()
    {
        if ($this->isHeadersSent())
            throw new \Exception('Headers was sent.');

        
        \Poirot\Http\Response\httpResponseCode($this->getMessageObject()->getStatusCode());
        
        /** @var iHeader $header */
        foreach ($this->getMessageObject()->headers() as $header)
            header( $header->render() );

        $this->isHeadersSent = true;
        return $this;
    }
1069315
public function send()
    {
        $this->addHeaders();

        $this->meta = call_user_func($this->map, $this->options);

        return $this;
    }
994877
public function addValidator($validator)
    {
        if (!($validator instanceof \Pop\Validator\AbstractValidator) && !is_callable($validator)) {
            throw new Exception('Error: The validator must be an instance of Pop\Validator\AbstractValidator or a callable object.');
        }
        $this->validators[] = $validator;
        return $this;
    }
251230
public function render($renderer)
    {
        $renderer->clearPageHeader();
        foreach ($this->elements as $element) {
            $renderer->addPageHeader($element);
        }
    }
1201285
public function addHeaderToRequest($header, $value)
    {
        $this->request = $this->request->withHeader($header, $value);
    }
964756
public function addHeaders(array $headers = [])
    {
        $this->headers = [];
        if($headers != []) {
            foreach ($headers as $header) {
                $this->headers[] = $header;
            }
        }
        return $this;
    }
1019622
public function addRequestHeader($header, $value) {
        $this->request = $this->request->withAddedHeader($header, $value);

        return $this;
    }
757004
private function add(JWESerializer $serializer): self
    {
        $this->serializers[$serializer->name()] = $serializer;

        return $this;
    }
588339
public function getHeader()
    {
        if (null == $this->header) {
            $header = $this->getNextDataSet();
            if (null === $header) {
                throw new Exception("Cannot retrieve header");
            }
            $this->setHeader($header);
        }

        return $this->header;
    }
814033
public function addHeader($name, $value)
    {
        if (isset($this->headers[$name])) {
            if (is_array($this->headers[$name])) {
                $this->headers[$name][] = $value;
            } else {
                $this->headers[$name] = $value;
            }
        } else {
            $this->headers[$name] = [$value];
        }

        return $this;
    }
989621
public function addHeader($key, $value) {
		if (is_array($value)) {
			foreach ($value as $v) {
				$this->addHeader($key, $v);
			}
		} else {
			$this->headers[$key][] = $value;
		}
		return $this;
	}
117819
public function add(AcceptHeaderItem $item)
    {
        $this->items[$item->getValue()] = $item;
        $this->sorted = false;

        return $this;
    }
967225
public function addHeaders($headers = array())
    {
        foreach ($headers as $header => $value) {
            $this->addHeader($header, $value);
        }
    }