final class ValueProjection
Restricted visibility: declared "@visibility root". Code outside that scope must not name this declaration.

Converts VALUES rows into their typed result-select projection.

Methods§

public function __construct(
    private PgSqlParser $parser,
    private ShadowIdentityAllocator $identityAllocator,
    private InsertRowRenderer $rowRenderer,
    private CastRenderer $castRenderer,
)

Shares the staged identity allocator with the owning INSERT transformer.

Parameters

$parserPgSqlParser
$identityAllocatorShadowIdentityAllocator
$rowRendererInsertRowRenderer
$castRendererCastRenderer
public function render<T>(
    string $sql,
    string $tableName,
    list<string> $tableColumns,
    list<string> $insertColumns,
    array{rows?: array<int, array<string, T>>, columnTypes?: array<string, ColumnDeclaration>, columnDefaults?: array<string, string>, identityStrategies?: array<string, IdentityGenerationStrategy>, storageTable?: string} $table,
): string

Projects each VALUES row with defaults, generated identities and declared casts.

Parameters

$sqlstring
$tableNamestring
$tableColumnslist<string>
$insertColumnslist<string>
$tablearray{rows?: array<int, array<string, T>>, columnTypes?: array<string, ColumnDeclaration>, columnDefaults?: array<string, string>, identityStrategies?: array<string, IdentityGenerationStrategy>, storageTable?: string}

Returns

string
Test cases 1
Called from 1
Calls 12

Private surface 4§

Implementation details, listed for orientation only.

private PgSqlParser $parser
private ShadowIdentityAllocator $identityAllocator
private InsertRowRenderer $rowRenderer
private CastRenderer $castRenderer

Test cases 6§

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

Dedicated tests 1
Other tests reaching this symbol 5

Relations§

Instantiated in 1
Method calls 1