src/Client.php
public function setHeader($name, $value)
    {
        if (!self::isValidHeader($name, $value)) {
            return false;
        }

        if (isset($this->requiredHttpHeaders[$name])) {
            return $this->requiredHttpHeaders[$name] === $value;
        }

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

        return true;
    }
public function setHeader($name, $value)
    {
        if (!self::isValidHeader($name, $value)) {
            return false;
        }

        if (isset($this->requiredHttpHeaders[$name])) {
            return $this->requiredHttpHeaders[$name] === $value;
        }

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

        return true;
    }
public function setHeader ( $ name , $ value ) { if ( ! self :: isValidHeader ( $ name , $ value ) ) { return false ; } if ( isset ( $ this -> requiredHttpHeaders [ $ name ] ) ) { return $ this -> requiredHttpHeaders [ $ name ] === $ value ; } $ this -> headers [ $ name ] = $ value ; return true ; }
Set add an additional HTTP header. This additional header will be sent
on each future HTTP request.

@param string $name
The name of the HTTP header (e.g. "Authorization").

@param string $value
The value of this HTTP header (e.g. "Basic YmFzaWM6YXV0aGVudGljYXRpb24=").

@return boolean
True iff the header has been set successfully (or has had the desired
value all along). Note that the CONTENT_TYPE, CONNECTION_TYPE, and
METHOD headers cannot be changed, because those headers are required.
Set add an additional HTTP header . This additional header will be sent on each future HTTP request .