RequestData
final class RequestData (View source)
Methods
Reports whether JSON is an explicitly preferred acceptable response representation.
Details
__construct
__construct(ServerRequestInterface $request, HttpRequestInspector $inspector = new HttpRequestInspector())
No description
request
ServerRequestInterface
request()
No description
input
mixed
input(string $key, mixed $default = null)
No description
query
mixed
query(string $key, mixed $default = null)
No description
queryAll
array
queryAll()
No description
post
mixed
post(string $key, mixed $default = null)
No description
postAll
array
postAll()
No description
header
string|null
header(string $name, string|null $default = null)
No description
headers
array
headers()
No description
cookie
mixed
cookie(string $name, mixed $default = null)
No description
cookies
array
cookies()
No description
server
mixed
server(string $key, mixed $default = null)
No description
serverAll
array
serverAll()
No description
body
string
body()
No description
jsonInput
mixed
jsonInput(string $key, mixed $default = null)
No description
jsonPayload
array
jsonPayload()
No description
isJsonRequest
bool
isJsonRequest()
No description
acceptsJson
bool
acceptsJson()
No description
wantsJson
bool
wantsJson()
Reports whether JSON is an explicitly preferred acceptable response representation.
expectsJson
bool
expectsJson()
No description
file
UploadedFileInterface|array|null
file(string $name)
No description
files
array
files()
No description
isAjaxRequest
bool
isAjaxRequest()
No description
ip
string|null
ip()
No description
userAgent
string|null
userAgent(string|null $default = null)
No description
referer
string|null
referer(string|null $default = null)
No description
method
string
method()
No description
isMethod
bool
isMethod(HttpMethod|string $method)
No description
isGet
bool
isGet()
No description
isPost
bool
isPost()
No description
isPut
bool
isPut()
No description
isPatch
bool
isPatch()
No description
isDelete
bool
isDelete()
No description
isHead
bool
isHead()
No description
isOptions
bool
isOptions()
No description
inputString
string
inputString(string $key, string $default = '')
No description
inputInt
int
inputInt(string $key, int $default = 0)
No description
inputFloat
float
inputFloat(string $key, float $default = 0.0)
No description
inputBool
bool
inputBool(string $key, bool $default = false)
No description