JsHandler implements JsonSerializable
FinalYes
Table of Contents
Interfaces
- JsonSerializable
Methods
- __construct() : mixed
- JsHandler constructor.
- getContext() : string|null
- getHandler() : string
- jsonSerialize() : mixed
- Specify data which should be serialized to JSON
- setContext() : JsHandler
- setHandler() : JsHandler
Methods
__construct()
JsHandler constructor.
public
__construct(string $handler[, string|null $context = null ]) : mixed
Parameters
- $handler : string
- $context : string|null = null
getContext()
public
getContext() : string|null
Return values
string|nullgetHandler()
public
getHandler() : string
Return values
stringjsonSerialize()
Specify data which should be serialized to JSON
public
jsonSerialize() : mixed
Tags
Return values
mixed —data which can be serialized by json_encode, which is a value of any type other than a resource.
setContext()
public
setContext(string|null $context) : JsHandler
Parameters
- $context : string|null
Return values
JsHandlersetHandler()
public
setHandler(string $handler) : JsHandler
Parameters
- $handler : string