classNamedAction
final class NamedAction
implements AlterCommand
uses Snapshot
Public API: explicitly declared with
@visibility public.A relation action on one named object.
One AlterTableCmd with a name; see NamedActionKind. The named index, constraint, tablespace, trigger or rule is looked up by the server; a version 1 context declares none of them. Source: https://www.postgresql.org/docs/17/sql-altertable.html.
$statement = (new \SqlSemantics\Platform\PostgreSql\Semantics())->analyze('ALTER TABLE t DISABLE TRIGGER audit');
[$statement->statement->commands[0]->kind, $statement->statement->commands[0]->name->value] // => [\SqlSemantics\Platform\PostgreSql\Statement\Table\Alter\NamedActionKind::DisableTrigger, 'audit']Properties§
public NamedActionKind $kindpublic Name $nameMethods§
public function __construct(public NamedActionKind $kind, public Name $name)Parameters
$kind | NamedActionKind | The action |
$name | Name | The object |
public function deriveClause(Derivation $derivation, Environment $environment): voidDerives nothing: the object is a catalog name.
Parameters
$derivation | Derivation | |
$environment | Environment |
public function render(Output $out): voidWrites the keywords and the name.
Parameters
$out | Output |
Calls 2
- method-call Output::keyword() line 49
- method-call NamedActionKind::keywords() line 49
Test cases 2§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 1
NamedActionTestcalls