web\HeaderCollection offsetExists()

offsetExists() public method Returns whether there is a header with the specified name. This method is required by the SPL interface ArrayAccess. It is implicitly called when you use something like isset($collection[$name]). public boolean offsetExists ( $name )$name string The header name return boolean Whether the named header exists

web\HeaderCollection offsetUnset()

offsetUnset() public method Removes the named header. This method is required by the SPL interface ArrayAccess. It is implicitly called when you use something like unset($collection[$name]). This is equivalent to remove(). public void offsetUnset ( $name )$name string The header name

web\HeaderCollection offsetSet()

offsetSet() public method Adds the header to the collection. This method is required by the SPL interface ArrayAccess. It is implicitly called when you use something like $collection[$name] = $header;. This is equivalent to add(). public void offsetSet ( $name, $value )$name string The header name $value string The header value to be added

web\HeaderCollection offsetGet()

offsetGet() public method Returns the header with the specified name. This method is required by the SPL interface ArrayAccess. It is implicitly called when you use something like $header = $collection[$name];. This is equivalent to get(). public string offsetGet ( $name )$name string The header name return string The header value with the specified name, null if the named header does not exist.

web\HeaderCollection has()

has() public method Returns a value indicating whether the named header exists. public boolean has ( $name )$name string The name of the header return boolean Whether the named header exists

web\HeaderCollection get()

get() public method Returns the named header(s). public string|array get ( $name, $default = null, $first = true )$name string The name of the header to return $default mixed The value to return in case the named header does not exist $first boolean Whether to only return the first header of the specified name. If false, all headers of the specified name will be returned. return string|array The named header(s). If $first is true, a string will be returned; If $first is false, an

web\HeaderCollection getCount()

getCount() public method Returns the number of headers in the collection. public integer getCount ( )return integer The number of headers in the collection.

web\HeaderCollection getIterator()

getIterator() public method Returns an iterator for traversing the headers in the collection. This method is required by the SPL interface IteratorAggregate. It will be implicitly called when you use foreach to traverse the collection. public ArrayIterator getIterator ( )return ArrayIterator An iterator for traversing the headers in the collection.

web\HeaderCollection $iterator

$iterator public read-only property An iterator for traversing the headers in the collection. public ArrayIterator getIterator ( )

web\HeaderCollection add()

add() public method Adds a new header. If there is already a header with the same name, the new one will be appended to it instead of replacing it. public $this add ( $name, $value )$name string The name of the header $value string The value of the header return $this The collection object itself