final class AlterTableMutation
    implements ShadowMutation

Applies ALTER TABLE operation to the virtual schema. This mutation modifies the table definition in the TableDefinitionRegistry.

Methods§

public function __construct(
    string $tableName,
    AlterStatement $alterStatement,
    TableDefinitionRegistry $registry,
    SchemaParser $schemaParser,
)

Configure the dependencies used by this operation.

Parameters

$tableNamestring
$alterStatementAlterStatement
$registryTableDefinitionRegistry
$schemaParserSchemaParser
public function apply(ShadowStore $store, array $rows): void

{@inheritDoc}

Parameters

$storeShadowStore
$rowsarray

Throws

RuntimeException
Test cases 117
Calls 12

Private surface 4§

Implementation details, listed for orientation only.

private string $tableName
private AlterStatement $alterStatement
private TableDefinitionRegistry $registry
private SchemaParser $schemaParser

Test cases 128§

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

Dedicated tests 118
Other tests reaching this symbol 10

Relations§

Instantiated in 1