final class KeyOptionRule
Restricted visibility: declared "@visibility SqlSemantics\Platform\MySql". Code outside that scope must not name this declaration.

Lowers index types and index options.

Rule: MYSQL-INDEX-OPTION-001. Scope: key_alg, key_using_alg, btree_or_rtree, index_type, index_type_clause, opt_index_type_clause, opt_index_name_and_type, normal_key_options, fulltext_key_options, spatial_key_options, normal_key_opts, fulltext_key_opts, spatial_key_opts, all_key_opt, normal_key_opt, fulltext_key_opt, spatial_key_opt, opt_index_options, index_options, index_option, opt_fulltext_index_options, fulltext_index_options, fulltext_index_option, opt_spatial_index_options, spatial_index_options, spatial_index_option, common_index_option, visibility. TYPE is a deprecated synonym of USING. Constructs: IndexAlgorithm and the IndexOption classes. Terminates: lists are flattened iteratively. Source: https://dev.mysql.com/doc/refman/8.4/en/create-index.html, https://dev.mysql.com/doc/refman/8.4/en/invisible-indexes.html. Status: Implemented.

Methods§

public function __construct(private Lowering $lowering)

Parameters

$loweringLoweringThe lowering this rule belongs to

Private surface 5§

Implementation details, listed for orientation only.

private const ALGORITHMS = ['btree_or_rtree: BTREE_SYM' => \SqlSemantics\Platform\MySql\Statement\Table\Ke…
private const LISTS = ['normal_key_opts: normal_key_opt', 'normal_key_opts: normal_key_opts normal_ke…
private const OPTIONAL = ['normal_key_options:' => false, 'normal_key_options: normal_key_opts' => true,…
private const FORWARD = ['normal_key_opt: all_key_opt' => true, 'normal_key_opt: key_using_alg' => true…
private Lowering $lowering

Test cases 8§

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

Dedicated tests 7
Other tests reaching this symbol 1

Relations§

Instantiated in 7
Method calls 10
Type declarations 1