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

Lowers the role commands.

Rule: PG-ROLE-LOWER-001. Scope: CreateRoleStmt, CreateUserStmt, CreateGroupStmt, OptRoleList, CreateOptRoleElem, AlterRoleStmt, AlterOptRoleList, AlterOptRoleElem, AlterRoleSetStmt, opt_in_database, AlterGroupStmt, DropRoleStmt. Constructors: CreateRole, AlterRole, AlterRoleSetting, AlterGroupMembers, DropRole and the RoleOption classes. The optional WITH before the options (LeafNoise) and ENCRYPTED before PASSWORD (AccessNoise) are noise. UNENCRYPTED PASSWORD and an unknown option word, which the server rejects in the grammar action, are lowered and reported by derivation. Termination: lists are flattened iteratively. Source: https://www.postgresql.org/docs/17/sql-createrole.html, https://www.postgresql.org/docs/17/sql-alterrole.html, https://www.postgresql.org/docs/17/sql-altergroup.html, https://www.postgresql.org/docs/17/sql-droprole.html. Status: Implemented.

Methods§

public function __construct(private Lowering $lowering)

Parameters

$loweringLoweringThe hub

Private surface 3§

Implementation details, listed for orientation only.

private const DROPS = ['DropRoleStmt: DROP ROLE role_list' => [\SqlSemantics\Platform\PostgreSql\Stat…
private const MEMBERS = ['AlterOptRoleElem: USER role_list' => [\SqlSemantics\Platform\PostgreSql\State…
private Lowering $lowering

Test cases 6§

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

Dedicated tests 6

Relations§

Instantiated in 1
Method calls 1