classToggleKeys
final class ToggleKeys
implements AlterCommand
uses Snapshot
Public API: explicitly declared with
@visibility public.ENABLE KEYS or DISABLE KEYS: a request to start or stop updating the nonunique indexes of a MyISAM table.
Mirrors PT_alter_table_enable_keys. Source: https://dev.mysql.com/doc/refman/8.4/en/alter-table.html#alter-table-index.
(new \SqlSemantics\Platform\MySql\Semantics())->analyze('ALTER TABLE t DISABLE KEYS')->statement->commands[0]->enable // => falseProperties§
public bool $enableMethods§
public function __construct(public bool $enable)Parameters
$enable | bool | Whether ENABLE (true) or DISABLE (false) is written |
public function deriveCommand(Derivation $derivation, Environment $scope): voidDerives nothing: the action holds no expression.
Parameters
$derivation | Derivation | |
$scope | Environment |
public function render(Output $out): voidTest cases 1§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
ToggleKeysTestcalls
Relations§
Instantiated in 2
- new SqlSemantics\Platform\MySql\Lowering\TableChange\Alter\ItemRule::simple() packages/sql-semantics-mysql/src/Lowering/TableChange/Alter/ItemRule.php:131
- new SqlSemantics\Platform\MySql\Lowering\TableChange\Alter\ItemRule::simple() packages/sql-semantics-mysql/src/Lowering/TableChange/Alter/ItemRule.php:132