Nexus API Reference

SwooleRequestTranslator
in package

FinalYes
Tags
psalm-api

Maps a Swoole\Http\Request into a PSR-7 ServerRequest backed by nyholm/psr7.

Table of Contents

Methods

toPsr7()  : ServerRequestInterface
Swoole\Http\Request exposes `$server`, `$header`, `$cookie`, `$get`, `$post`, `$files` as plain `mixed` (the stubs don't model them precisely). The runtime guarantees these are arrays or null and we defend each access; suppressing Psalm here keeps the code linear.

Methods

toPsr7()

Swoole\Http\Request exposes `$server`, `$header`, `$cookie`, `$get`, `$post`, `$files` as plain `mixed` (the stubs don't model them precisely). The runtime guarantees these are arrays or null and we defend each access; suppressing Psalm here keeps the code linear.

public static toPsr7(Request $req) : ServerRequestInterface
Parameters
$req : Request
Tags
psalm-suppress

MixedAssignment

psalm-suppress

MixedArrayAccess

psalm-suppress

MixedArgument

psalm-suppress

MixedArgumentTypeCoercion

Return values
ServerRequestInterface

        
On this page

Search results