classJsonArgument
final class JsonArgument
implements Clause
uses Snapshot
Public API: explicitly declared with
@visibility public.A variable passed to a JSON path with PASSING: value AS name.
Mirrors PostgreSQL's JsonArgument node. Source: https://www.postgresql.org/docs/17/functions-json.html#FUNCTIONS-SQLJSON-QUERYING.
$argument = new \SqlSemantics\Platform\PostgreSql\Statement\Invocation\Json\Query\JsonArgument(new \SqlSemantics\Platform\PostgreSql\Statement\Invocation\Json\JsonValueExpression(new \SqlSemantics\Platform\PostgreSql\Statement\Literal\NullLiteral()), new \SqlSemantics\Platform\PostgreSql\Model\Statement\Identifier\Name('x'));
$argument->name->value // => 'x'Properties§
public JsonValueExpression $valuepublic Name $nameMethods§
public function __construct(public JsonValueExpression $value, public Name $name)Parameters
$value | JsonValueExpression | The value |
$name | Name | The variable name the path uses |
public function deriveClause(Derivation $derivation, Environment $environment): voidDerives the value.
Parameters
$derivation | Derivation | |
$environment | Environment |
Test cases 1
Calls 1
- method-call JsonValueExpression::deriveValue() line 44
public function render(Output $out): voidWrites the value and its name.
Parameters
$out | Output |
Test cases 1
Calls 2
- method-call Output::node() line 52
- class-const NameUse::Label() line 52
Test cases 3§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.