final class OpenHandler
    implements Relation
    uses Snapshot
Public API: explicitly declared with @visibility public.

The open handler a HANDLER ... READ reads from, named by the alias or table name of its HANDLER ... OPEN.

Rule: MYSQL-HANDLER-TABLE-001. A handler is opened by an earlier statement of the session; which table it reads is session state, so its row shape is open and depends on that state. The WHERE condition of the read sees the handler under its name. Terminates: no child. Source: https://dev.mysql.com/doc/refman/8.4/en/handler.html. Status: Implemented.

Reading the handler of a readdoctest
$read = (new \SqlSemantics\Platform\MySql\Semantics())->analyze('HANDLER h READ FIRST');
    $read->statement->handler->name->value // => 'h'

Properties§

public Name $name

Methods§

public function __construct(public Name $name)

Parameters

$nameNameThe name of the handler
public function deriveRelation(Derivation $derivation, Environment $environment): RelationFact

Derives the open row shape of the handler.

Parameters

$derivationDerivation
$environmentEnvironment
Calls 3
public function render(Output $out): void

Writes the handler name.

Parameters

$outOutput
Test cases 1
Calls 2

Test cases 2§

Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.

Dedicated tests 1
Other tests reaching this symbol 1

Relations§

Instantiated in 1
Type declarations 5