final class Neon

Facade for parsing and encoding the NEON format.

Constants

Chain

CHAIN

deprecated BLOCK

Methods

static string
encode(mixed $value, bool $blockMode = false, string $indentation = "\t")

Encodes a PHP value to a NEON string.

static mixed
decode(string $input)

Parses a NEON string and returns the corresponding PHP value.

static mixed
decodeFile(string $file)

Parses a NEON file and returns the corresponding PHP value. Strips the UTF-8 BOM if present.

Details

at line 29
static string encode(mixed $value, bool $blockMode = false, string $indentation = "\t")

Encodes a PHP value to a NEON string.

Parameters

mixed $value
bool $blockMode
string $indentation

Return Value

string

at line 41
static mixed decode(string $input)

Parses a NEON string and returns the corresponding PHP value.

Parameters

string $input

Return Value

mixed

at line 51
static mixed decodeFile(string $file)

Parses a NEON file and returns the corresponding PHP value. Strips the UTF-8 BOM if present.

Parameters

string $file

Return Value

mixed