Icicle\Http\Message\Cookie\SetCookie::toHeader PHP Метод

toHeader() публичный Метод

public toHeader ( ) : string
Результат string
    public function toHeader() : string
    {
        $line = parent::toHeader();
        if (0 !== $this->expires) {
            $line .= '; Expires=' . $this->encodeDate($this->expires);
        }
        if ('' !== $this->path) {
            $line .= '; Path=' . $this->encodePath($this->path);
        }
        if ('' !== $this->domain) {
            $line .= '; Domain=' . $this->domain;
        }
        if ($this->secure) {
            $line .= '; Secure';
        }
        if ($this->httpOnly) {
            $line .= '; HttpOnly';
        }
        return $line;
    }