Getter for header line.

@param string $name The name of the heade to return line for

@author Benjamin Carl <opensource@clickalicious.de>
@return string The header line if set
@access public
551287
public function getHeaderLine($name)
    {
        $internalName = strtolower($name);
        return (true === isset($this->headers[$internalName])) ? implode(',', $this->headers[$internalName]) : '';
    }
440847
public function getHeader($name, $default = null)
    {
        if (!$this->request) {
            return $this->getRequest()->getHeader($name);
        }
        return parent::getHeader($name, $default);
    }
1011204
public function get($name)
    {
        $definition = null;
        if ($this->has($name)) {
            $definition = $this->_definitionSource[$this->_names[$name]];
        }
        return $definition;
    }
653218
public function getRequiredLines($name)
    {
        $name = $this->normalizeName($name);
        
        if(!$this->existsNormalized($name)) {
            throw new \PHPixie\HTTP\Exception("Header '$name' is not set");
        }
        
        return $this->headers[$name];
    }
1308771
public function getHeader($name)
    {
        $rawHeader = $this->getRawHeader($name);
        if ($rawHeader === false) {
            return false;
        }

        return $this->decodeHeader($rawHeader);
    }
805156
public static function get(string $name)
    {
        return (isset($_GET[$name]) && $_GET[$name] != '') ? $_GET[$name] : '';
    }
107318
public function getHeader(string $name)
    {
        $name = strtolower($name);
        foreach ($this->headers as $current => $value) {
            if (strtolower($current) == $name) {
                return $value;
            }
        }

        return null;
    }
1833
final public function &__get($name)
    {
        $value = $this->data[$name];

        //Apply accessor
        $this->applyModifier($name, $value, 'get');

        return $value;
    }
642488
public function getHeaders($name = null)
    {
        if (is_null($name)) {
            return $this->headers;
        } else {
            return $this->getHeader($name);
        }
    }
356506
public function getResponseHeader($name)
    {
        $headers = $this->driver->getResponseHeaders();

        $name = strtolower($name);
        $headers = array_change_key_case($headers, CASE_LOWER);

        if (!isset($headers[$name])) {
            return null;
        }

        return is_array($headers[$name]) ? $headers[$name][0] : $headers[$name];
    }
464442
public function getHeader($name) : array
    {
        return (($this->headers->has($name) === true) ? $this->headers->get($name) : []);
    }
214120
public function getHeaders(string $name = null)
    {
        if (is_null($name)) {
            return $this->get('headers');
        }

        return $this->get('headers', $name);
    }
686930
public function getLastHeader(string $name) : ?string
    {
        $name = strtolower($name);

        return isset($this->headers[$name]) ? end($this->headers[$name]) : null;
    }
1225022
public function get(string $name, $default = null)
    {
        $key = strtolower($name);
        if (!array_key_exists($key, $this->headers)) {
            return $default;
        }

        return $this->headers[$key]->getValuesAsString();
    }
211999
public function getByName($name)
    {
        Types::assert(['string' => [$name]]);

        $name = strtolower($name);

        if ( ! array_key_exists($name, $this->headers))
        {
            return [];
        }

        return $this->headers[$name];
    }
868429
public function getByName($name)
	{
		return isset($this->nameList[$name]) ? $this->nameList[$name] : null;
	}
616617
private function get(string $name){
		$method = 'magic_get_'.$name;

		return \method_exists($this, $method) ? $this->$method() : null;
	}