classDatabaseSchemaCache
final class DatabaseSchemaCache
Restricted visibility: declared "@visibility root". Code outside that scope must not name this declaration.
Caches reflected table schemas for one connection.
Methods§
public function __construct(
private PDO $connection,
private SchemaFetcherInterface $schemaFetcher,
)Reflects missing tables through the selected dialect fetcher.
Parameters
$connection | PDO | |
$schemaFetcher | SchemaFetcherInterface |
public function getSchema(string $tableName): TableSchemaGet or fetch schema for a table.
Parameters
$tableName | string |
Returns
Test cases 2
Called from 1
Calls 2
- function-call
str_replaceline 35 - method-call SchemaFetcherInterface::fetchSchema() line 38
public function clear(): voidInvalidates reflected schemas after database DDL changes.
Test cases 1
Called from 1
Private surface 3§
Implementation details, listed for orientation only.
private array<string, TableSchema> $schemaCache = []private PDO $connectionprivate SchemaFetcherInterface $schemaFetcherTest cases 4§
Test cases that cover or call this symbol, from the coverage report and from the analyzed test sources.
Dedicated tests 2
Other tests reaching this symbol 2
SqliteIntegrationTestcallsDatabaseFixtureProviderTestcalls