final class OutputSlot
    uses Snapshot
Public API: explicitly declared with @visibility public.

One output position of a relation occurrence or of a query.

A slot is not a declaration. A slot of a named table refers to the declared column; a slot a join re-exposes refers to the input slot it comes from and carries its own NULL fact, so an outer join never changes a declaration.

Reading the slot of a query fielddoctest
$semantics = new \SqlSemantics\Platform\PostgreSql\Semantics();
    $table = $semantics->analyze('CREATE TABLE t (a INTEGER NOT NULL)');
    $semantics->analyze('SELECT a FROM t', [$table])->field('a')->slot->nullability // => \SqlSemantics\Platform\PostgreSql\Model\Statement\Type\Nullability::NotNull

Properties§

public list<MissingInput> $unnamed
public Name|null $name
public TypeFact $type
public Nullability $nullability
public Column|null $column = null
public OutputSlot|null $origin = null

Methods§

public function __construct(
    public Name|null $name,
    public TypeFact $type,
    public Nullability $nullability,
    public Column|null $column = null,
    public OutputSlot|null $origin = null,
    list<MissingInput> $unnamed = [],
)

Parameters

$nameName|nullThe output name, or null when the position has none
$typeTypeFactWhat is known about the type at this position
$nullabilityNullabilityWhether the position can be NULL
$columnColumn|nullThe declared column when the position is that column itself
$originOutputSlot|nullThe input slot this position re-exposes, for example through a join
$unnamedlist<MissingInput>The inputs whose absence leaves the name of an unnamed position undecided; empty when it has no name at all
Calls 3

Test cases 34§

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

Other tests reaching this symbol 34

Relations§

Instantiated in 45
Method calls 2
Constant reads 2
Type declarations 10