final class IndexRule
Restricted visibility: declared "@visibility SqlSemantics". Code outside that scope must not name this declaration.

Lowers CREATE INDEX and the index keys several statements share.

Rule: PG-INDEX-LOWER-001. Scope: IndexStmt, opt_unique, access_method_clause, index_params, index_elem, index_elem_options, opt_include, index_including_params, OptTableSpace, OptWhereClause. Constructors: CreateIndex, IndexElement, ColumnKey, ExpressionKey. A key written as a name is a ColumnKey; a function call or a parenthesized expression is an ExpressionKey that keeps whether the parentheses are written. Termination: lists are flattened iteratively. Source: https://www.postgresql.org/docs/17/sql-createindex.html. Status: Implemented.

Methods§

public function __construct(private Lowering $lowering)

Parameters

$loweringLoweringThe hub
public function unique(Node $flag): bool
public function included(Node $clause): list<IndexElement>
public function options(ColumnKey|ExpressionKey $key, Form $form): IndexElement

Private surface 1§

Implementation details, listed for orientation only.

private Lowering $lowering

Test cases 9§

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

Dedicated tests 9

Relations§

Instantiated in 9
Method calls 10