Flow PHP

Json

Read onlyYes
FinalYes

Constants

FLAGS  : int = \JSON_THROW_ON_ERROR | \JSON_PRESERVE_ZERO_FRAC...

Methods

decode()  : array<string|int, mixed>
encode()  : string

Constants

FLAGS

public int FLAGS = \JSON_THROW_ON_ERROR | \JSON_PRESERVE_ZERO_FRACTION | \JSON_UNESCAPED_SLASHES

Methods

decode()

public static decode(string $json) : array<string|int, mixed>
Parameters
$json : string
Tags
throws
InvalidArgumentException

when the document is not a JSON array or object

JsonException
Return values
array<string|int, mixed>

encode()

public static encode(array<string|int, mixed> $data) : string
Parameters
$data : array<string|int, mixed>
Tags
throws
JsonException
Return values
string
On this page

Search results