final class MySqlMutationResolver

Resolves the appropriate ShadowMutation for a given SQL statement.

This class depends on domain state (ShadowStore, TableDefinitionRegistry) to determine primary keys, column metadata, and table existence needed for mutation construction.

Methods§

public function __construct(
    ShadowStore $shadowStore,
    TableDefinitionRegistry $registry,
    SchemaParser $schemaParser,
    UpdateTransformer $updateTransformer,
    DeleteTransformer $deleteTransformer,
)

Configure the dependencies used by this operation.

Parameters

$shadowStoreShadowStore
$registryTableDefinitionRegistry
$schemaParserSchemaParser
$updateTransformerUpdateTransformer
$deleteTransformerDeleteTransformer
public function resolve(string $sql, Statement $statement, QueryKind $kind): ?ShadowMutation

Resolve mutation for a given statement.

Parameters

$sqlstring
$statementStatement
$kindQueryKind
Test cases 75
Called from 2
Calls 11

Private surface 5§

Implementation details, listed for orientation only.

private ShadowStore $shadowStore
private TableDefinitionRegistry $registry
private SchemaParser $schemaParser
private UpdateTransformer $updateTransformer
private DeleteTransformer $deleteTransformer

Test cases 230§

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

Dedicated tests 75
Other tests reaching this symbol 155

Relations§

Instantiated in 1
Method calls 2
Type declarations 3