Methods summary
public
|
#
__construct( string $header, array $values = array(), string $glue = ', ' )
Construct a new header object
Construct a new header object
Parameters
- $header
string $header Name of the header
- $values
array $values Values of the header
- $glue
string $glue Glue used to combine multiple values into a string
|
public
string
|
#
__toString( )
Convert the header to a string
Convert the header to a string
Returns
string
|
public
Guzzle\Http\Message\Header
|
#
add( string $value, string $header = null )
Add a value to the list of header values
Add a value to the list of header values
Parameters
- $value
string $value Value to add
- $header
string $header The exact header casing to add with. Defaults to the name of the header.
Returns
|
public
string
|
#
getName( )
Get the name of the header
Get the name of the header
Returns
string
|
public
Guzzle\Http\Message\Header
|
#
setGlue( string $glue )
Change the glue used to implode the values
Change the glue used to implode the values
Parameters
- $glue
string $glue Glue used to implode multiple values
Returns
|
public
string
|
#
getGlue( )
Get the glue used to implode multiple values into a string
Get the glue used to implode multiple values into a string
Returns
string
|
public
Guzzle\Http\Message\Header
|
#
normalize( boolean $explodeOnGlue = false )
Normalize the header to be a single header with an array of values
Normalize the header to be a single header with an array of values
Parameters
- $explodeOnGlue
boolean $explodeOnGlue Set to true to explode each header value on the glue of the
header
Returns
|
public
boolean
|
#
hasValue( string $searchValue, boolean $caseInsensitive = false )
Check if the collection of headers has a particular value
Check if the collection of headers has a particular value
Parameters
- $searchValue
string $searchValue Value to search for
- $caseInsensitive
boolean $caseInsensitive Set to TRUE to use a case insensitive search
Returns
boolean
|
public
Guzzle\Http\Message\Header
|
#
removeValue( string $searchValue )
Remove a specific value from the header
Remove a specific value from the header
Parameters
- $searchValue
string $searchValue Value to remove
Returns
|
public
array
|
#
toArray( )
Get all of the header values as a flat array Get the array representation of
an object
Get all of the header values as a flat array Get the array representation of
an object
Returns
array
Implementation of
|
public
array
|
#
raw( )
Get the raw data array of the headers. This array is represented as an
associative array of the various cases that might be stored in the header and an
array of values associated with each case variation.
Get the raw data array of the headers. This array is represented as an
associative array of the various cases that might be stored in the header and an
array of values associated with each case variation.
Returns
array
|
public
integer
|
#
count( )
Returns the total number of header values
Returns the total number of header values
Returns
integer
Implementation of
|
public
ArrayIterator
|
#
getIterator( )
Get an iterator that can be used to easily iterate over each header value
Get an iterator that can be used to easily iterate over each header value
Returns
Implementation of
|