A classe EventHttpRequest

(PECL event >= 1.4.0-beta)

Introdução

Representa uma solicitação HTTP.

Resumo da classe

class EventHttpRequest {
/* Constantes */
const int CMD_GET = 1;
const int CMD_POST = 2;
const int CMD_HEAD = 4;
const int CMD_PUT = 8;
const int CMD_DELETE = 16;
const int CMD_OPTIONS = 32;
const int CMD_TRACE = 64;
const int CMD_CONNECT = 128;
const int CMD_PATCH = 256;
const int INPUT_HEADER = 1;
const int OUTPUT_HEADER = 2;
/* Métodos */
public addHeader( string $key , string $value , int $type ): bool
public cancel(): void
public clearHeaders(): void
public __construct( callable $callback , mixed $data = null )
public findHeader( string $key , string $type ): void
public free(): void
public getCommand(): void
public getHost(): string
public getUri(): string
public removeHeader( string $key , string $type ): void
public sendError( int $error , string $reason = null ): void
public sendReply( int $code , string $reason , EventBuffer $buf = ?): void
public sendReplyEnd(): void
public sendReplyStart( int $code , string $reason ): void
}

Constantes pré-definidas

EventHttpRequest::CMD_GET

Método GET (comando)

EventHttpRequest::CMD_POST

Método POST (comando)

EventHttpRequest::CMD_HEAD

Método HEAD (comando)

EventHttpRequest::CMD_PUT

Método PUT (comando)

EventHttpRequest::CMD_DELETE

Comando DELETE (método)

EventHttpRequest::CMD_OPTIONS

Método OPTIONS (comando)

EventHttpRequest::CMD_TRACE

Método TRACE (comando)

EventHttpRequest::CMD_CONNECT

Método CONNECT (comando)

EventHttpRequest::CMD_PATCH

Método PATCH (comando)

EventHttpRequest::INPUT_HEADER

Solicitar tipo de cabeçalho de entrada.

EventHttpRequest::OUTPUT_HEADER

Solicitar tipo de cabeçalho de saída.

Table of Contents