src/Net/HTTP/Header/Field/Parser.php
static public function parse( $headerFieldString, $decodeQualifiedValues = FALSE ){
		if( !preg_match( '/^\S+:\s*.+$/', trim( $headerFieldString ) ) )
		 	throw new InvalidArgumentException( 'Given string is not an HTTP header' );
		list( $key, $value )	= preg_split( '/:/', trim( $headerFieldString ), 2 );
		$value	= trim( $value );
		if( $decodeQualifiedValues )
			$value	= self::decodeQualifiedValues( $value );
		return new Net_HTTP_Header_Field( trim( $key ), $value );
	}
static public function parse( $headerFieldString, $decodeQualifiedValues = FALSE ){
		if( !preg_match( '/^\S+:\s*.+$/', trim( $headerFieldString ) ) )
		 	throw new InvalidArgumentException( 'Given string is not an HTTP header' );
		list( $key, $value )	= preg_split( '/:/', trim( $headerFieldString ), 2 );
		$value	= trim( $value );
		if( $decodeQualifiedValues )
			$value	= self::decodeQualifiedValues( $value );
		return new Net_HTTP_Header_Field( trim( $key ), $value );
	}
static public function parse ( $ headerFieldString , $ decodeQualifiedValues = FALSE ) { if ( ! preg_match ( '/^\S+:\s*.+$/' , trim ( $ headerFieldString ) ) ) throw new InvalidArgumentException ( 'Given string is not an HTTP header' ) ; list ( $ key , $ value ) = preg_split ( '/:/' , trim ( $ headerFieldString ) , 2 ) ; $ value = trim ( $ value ) ; if ( $ decodeQualifiedValues ) $ value = self :: decodeQualifiedValues ( $ value ) ; return new Net_HTTP_Header_Field ( trim ( $ key ) , $ value ) ; }
Parses a header field string into a header field object.

@static
@access		public
@param		string		$headerFieldString		String to header field to parse
@param		boolean		$decodeQualifiedValues	Flag: decode qualified values (default: FALSE)
@return		Net_HTTP_Header_Field				Header field object
@throws		InvalidArgumentException			If given string is not a valid header field
Parses a header field string into a header field object .