The HttpMessage class

(Информация о версии неизвестна, возможно, только в SVN)

Обзор классов


HttpMessage implements Iterator , Countable , Serializable {
public void addHeaders ( array $headers [, bool $append = false ] )
public void __construct ([ string $message ] )
public HttpMessage detach ( void )
static public HttpMessage factory ([ string $raw_message [, string $class_name = "HttpMessage" ]] )
static public HttpMessage fromEnv ( int $message_type [, string $class_name = "HttpMessage" ] )
static public HttpMessage fromString ([ string $raw_message [, string $class_name = "HttpMessage" ]] )
public string getBody ( void )
public string getHeader ( string $header )
public array getHeaders ( void )
public string getHttpVersion ( void )
public HttpMessage getParentMessage ( void )
public string getRequestMethod ( void )
public string getRequestUrl ( void )
public int getResponseCode ( void )
public string getResponseStatus ( void )
public int getType ( void )
public string guessContentType ( string $magic_file [, int $magic_mode = MAGIC_MIME ] )
public void prepend ( HttpMessage $message [, bool $top = true ] )
public HttpMessage reverse ( void )
public bool send ( void )
public void setBody ( string $body )
public void setHeaders ( array $headers )
public bool setHttpVersion ( string $version )
public bool setRequestMethod ( string $method )
public bool setRequestUrl ( string $url )
public bool setResponseCode ( int $code )
public bool setResponseStatus ( string $status )
public void setType ( int $type )
public HttpRequest|HttpResponse toMessageTypeObject ( void )
public string toString ([ bool $include_parent = false ] )
}

Class Members

Свойства

Instance Properties
Modifiers Type Name Description
protectedinttypemessage type
protectedstringbodymessage body
protectedfloathttpVersionHTTP protocol version
protectedarrayheadersmessage headers
protectedstringrequestMethodrequest method name
protectedrequestUrlstringrequest URL
protectedintresponseCoderesponse code
protectedstringresponseStatusresponse status message
protectedHttpMessageparentMessagereference to parent message

Замечание:

None of these default properties can be accessed by reference, array key/index notation nor be used in increment or decrement operations.


Предопределенные константы

Type Name Description
intTYPE_NONEmessage has is of no specific type
intTYPE_REQUESTmessage is a request style HTTP message
intTYPE_RESPONSEmessage is a response style HTTP message

Содержание


Описание класса httpmessage, примеры использования класса httpmessage.



Смотрите также:
Описание на ru2.php.net
Описание на php.ru