PHP Трейт Kraken\Channel\Record\RequestRecordStorage

Показать файл Открыть проект

Защищенные свойства (Protected)

Свойство Тип Описание
$reqs RequestRecord[]

Защищенные методы

Метод Описание
addRequest ( string $pid, RequestRecord $request ) Add new RequestRecord to storage.
cancelRequest ( string $pid, Erro\Error | Exceptio\Exception | ThrowableProxy $ex ) Cancel RequestRecord if it exists that has protocol ID equal to $pid.
createRequest ( string $pid, callable $success = null, callable $failure = null, callable $cancel = null, float $timeout ) : RequestRecord Create RequestRecord.
existsRequest ( string $pid ) : boolean Check if RequestRecord with given protocol ID exists.
expireRequests ( ) Cancel overdue Requests.
getRequest ( string $pid ) : RequestRecord | null Return RequestRecord if it exists or null if it does not exist.
rejectRequest ( string $pid, Erro\Error | Exceptio\Exception | ThrowableProxy $ex ) Reject RequestRecord if it exists that has protocol ID equal to $pid.
resolveRequest ( string $pid, string $message ) Resolve RequestRecord if it exists that has protocol ID equal to $pid.

Описание методов

addRequest() защищенный Метод

Add new RequestRecord to storage.
protected addRequest ( string $pid, RequestRecord $request )
$pid string
$request RequestRecord

cancelRequest() защищенный Метод

Cancel RequestRecord if it exists that has protocol ID equal to $pid.
protected cancelRequest ( string $pid, Erro\Error | Exceptio\Exception | ThrowableProxy $ex )
$pid string
$ex Erro\Error | Exceptio\Exception | Kraken\Throwable\ThrowableProxy

createRequest() защищенный Метод

Create RequestRecord.
protected createRequest ( string $pid, callable $success = null, callable $failure = null, callable $cancel = null, float $timeout ) : RequestRecord
$pid string
$success callable
$failure callable
$cancel callable
$timeout float
Результат RequestRecord

existsRequest() защищенный Метод

Check if RequestRecord with given protocol ID exists.
protected existsRequest ( string $pid ) : boolean
$pid string
Результат boolean

expireRequests() защищенный Метод

Cancel overdue Requests.
protected expireRequests ( )

getRequest() защищенный Метод

Return RequestRecord if it exists or null if it does not exist.
protected getRequest ( string $pid ) : RequestRecord | null
$pid string
Результат RequestRecord | null

rejectRequest() защищенный Метод

Reject RequestRecord if it exists that has protocol ID equal to $pid.
protected rejectRequest ( string $pid, Erro\Error | Exceptio\Exception | ThrowableProxy $ex )
$pid string
$ex Erro\Error | Exceptio\Exception | Kraken\Throwable\ThrowableProxy

resolveRequest() защищенный Метод

Resolve RequestRecord if it exists that has protocol ID equal to $pid.
protected resolveRequest ( string $pid, string $message )
$pid string
$message string

Описание свойств

$reqs защищенное свойство

protected RequestRecord[],Kraken\Channel\Record $reqs
Результат RequestRecord[]