classHandlerRule
final class HandlerRule
Restricted visibility: declared "@visibility SqlSemantics\Platform\MySql\Lowering\Dml". Code outside that scope must not name this declaration.
Lowers HANDLER of every release.
Rule: MYSQL-HANDLER-LOWERING-001. Scope: handler, handler_read_or_scan (5.6, 5.7); handler_stmt (8.0 and later); handler_scan_function, handler_rkey_function, handler_rkey_mode. OPEN and CLOSE are HandlerOpen and HandlerClose; a read is a scan (HandlerScan), an index read (HandlerIndexRead) or an index seek (HandlerIndexSeek). Terminates: the parts are strict subtrees. Source: https://dev.mysql.com/doc/refman/8.4/en/handler.html. Status: Implemented.
Methods§
public function __construct(private Lowering $lowering)Parameters
$lowering | Lowering | The lowering this rule belongs to |
Lowers a node of handler or handler_stmt.
Parameters
$form | Form |
Returns
Throws
ImplementationGap When a production has no ruleCalled from 1
Calls 4
- new HandlerOpen line 88
- method-call Form::node() line 88
- new HandlerClose line 90
- method-call HandlerRule::read() line 94
Lowers a read of a handler.
Parameters
$form | Form |
Returns
Throws
ImplementationGap When a production has no ruleCalled from 1
Calls 8
- class-const HandlerRule::READS() line 105
- static-call ImplementationGap::production() line 105
- method-call Form::node() line 106
- new OpenHandler line 107
- method-call Lowering::form() line 110
- class-const HandlerRule::SCANS() line 114
- new HandlerScan line 115
- method-call HandlerRule::index() line 118
public function index(
OpenHandler $handler,
Node $index,
Form $function,
?Scalar $where,
?Limit $limit,
Form|null $seek = null,
): StatementLowers an index read or an index seek.
Parameters
Returns
Throws
ImplementationGap When a production has no ruleCalled from 2
Calls 7
- class-const HandlerRule::DIRECTIONS() line 135
- new HandlerIndexRead line 136
- method-call Lowering::form() line 140
- method-call Form::node() line 140
- static-call ImplementationGap::production() line 141
- class-const HandlerRule::MODES() line 143
- new HandlerIndexSeek line 145
Private surface 5§
Implementation details, listed for orientation only.
private const READS = ['handler: HANDLER_SYM table_ident_nodb READ_SYM handler_read_or_scan where_cla…private const SCANS = ['handler_scan_function: FIRST_SYM' => \SqlSemantics\Platform\MySql\Statement\D…private const DIRECTIONS = ['handler_rkey_function: FIRST_SYM' => \SqlSemantics\Platform\MySql\Statement\D…private const MODES = ['handler_rkey_mode: EQ' => \SqlSemantics\Platform\MySql\Statement\Dml\Handler\…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
HandlerRuleTestcalls