\Support\HttpRequestSingle

请求单例

Summary

Methods
Properties
Constants
__construct()
new()
revolve()
build()
$hash
$method
$url
$version
$header
$headers
$body
$bodyLength
$statusCode
$client
$upload
$boundary
$uploadHandler
No constants found
No protected methods found
No protected properties found
N/A
parseRequestHead()
No private properties found
N/A

Properties

$hash

$hash : string

Type

string

$method

$method : string

Type

string

$url

$url : string

Type

string

$version

$version : string

Type

string

$header

$header : string

Type

string

$headers

$headers : array

Type

array

$body

$body : string

Type

string

$bodyLength

$bodyLength : int

Type

int

$statusCode

$statusCode : int

Type

int

$client

$client : \Worker\Socket\TCPConnection

Type

TCPConnection

$upload

$upload : bool

Type

bool

$boundary

$boundary : string

Type

string

$uploadHandler

$uploadHandler : \Support\Http\RequestUpload

Type

\Support\Http\RequestUpload —

Methods

__construct()

__construct(\Worker\Socket\TCPConnection  $client) : mixed

RequestSingle constructor.

Parameters

\Worker\Socket\TCPConnection $client

Returns

mixed —

new()

new(\Worker\Socket\TCPConnection  $client) : self

Parameters

\Worker\Socket\TCPConnection $client

Returns

self —

revolve()

revolve(string  $context) : \Support\Http\RequestSingle

Push request body

Parameters

string $context

Throws

\Support\Http\RequestSingleException

Returns

\Support\Http\RequestSingle —

build()

build() : \Support\Http\Request

打包请求

Returns

\Support\Http\Request —

parseRequestHead()

parseRequestHead(string  $context) : bool

Parameters

string $context

Throws

\Support\Http\RequestSingleException

Returns

bool —