Skip to content

API reference / Quittio \ Core \ View

FormattedValue

final readonly class in quittio/core · implements JsonSerializable, Stringable

Quittio\Core\View\FormattedValue · Source

A value for templates: formatted for display and available in raw form. Casting to string returns the formatted value, so {{ $value }} prints it.

Properties#

PropertyTypeDescription
$formatted readonlystring
$raw readonlymixed

Methods#

MethodDescription
->__construct()
->__toString()
->jsonSerialize()

__construct()#

public function __construct(string $formatted, mixed $raw = null)
ParameterTypeDescription
$formattedstring
$rawmixed = null

__toString()#

public function __toString(): string
Returns
string

jsonSerialize()#

public function jsonSerialize(): string
Returns
string

The open core packages are MIT licensed. The legal wording of the country packs must be confirmed by a tax adviser.