classCallRule
final class CallRule
Lowers function call productions.
Rule: SQLITE-EXPR-CALL-001. Scope: the expr productions of function calls; filter_over, filter_clause, over_clause. A call keeps its name, its arguments in order, the star form, the quantifier, the argument ordering, the filter and the window. Terminates: every part is a strict subtree. Source: https://sqlite.org/lang_expr.html#functions, https://sqlite.org/windowfunctions.html. Status: Implemented.
Methods§
public function __construct(private Lowering $lowering)Parameters
$lowering | Lowering | The lowering this rule belongs to |
Lowers a function call.
Parameters
$form | Form |
Returns
Throws
ImplementationGap When the production has no ruleCalled from 1
Calls 5
- new FunctionCall line 47
- method-call CallRule::name() line 47
- method-call Form::node() line 47
- method-call CallRule::filterOver() line 50
- static-call ImplementationGap::production() line 53
Lowers the function name of a call production and records it as an operand leaf.
Parameters
$form | Form |
Returns
Called from 6
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:47
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:48
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:49
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:50
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:51
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:52
Calls 1
- method-call Form::token() line 62
public function filterOver(Node $clause): array{Scalar|null, WindowSpec|Name|null}Lowers a filter_over into the filter predicate and the window.
Parameters
$clause | Node |
Returns
array{Scalar|null, WindowSpec|Name|null}Throws
ImplementationGap When the production has no ruleCalled from 3
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:50
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:51
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::expression() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:52
Calls 3
- method-call CallRule::filter() line 76
- method-call CallRule::over() line 76
- static-call ImplementationGap::production() line 79
Lowers a filter_clause into its predicate.
Parameters
$clause | Node |
Returns
Throws
ImplementationGap When the production has no ruleCalled from 2
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::filterOver() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:76
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::filterOver() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:78
Calls 1
- static-call ImplementationGap::production() line 94
public function over(Node $clause): WindowSpec|NameLowers an over_clause into a window specification or a window name.
Parameters
$clause | Node |
Returns
Throws
ImplementationGap When the production has no ruleCalled from 2
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::filterOver() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:76
- method-call SqlSemantics\Platform\Sqlite\Lowering\Expression\CallRule::filterOver() packages/sql-semantics-sqlite/src/Lowering/Expression/CallRule.php:77
Calls 1
- static-call ImplementationGap::production() line 110
Private surface 1§
Implementation details, listed for orientation only.
private Lowering $loweringTest cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
CallRuleTestcalls