final class ConditionalColumn
    implements Resolution
    uses Snapshot
Public API: explicitly declared with @visibility public.

A name whose resolution depends on declarations missing from the context.

The candidates are the places the name can resolve to once the missing inputs are known. A known candidate in a farther scope is not chosen while a nearer scope is incompletely known.

Keeping the candidate occurrence of an undeclared tabledoctest
$query = (new \SqlSemantics\Platform\Sqlite\Semantics())->analyze('SELECT a FROM t');
    $resolution = $query->field('a')->resolution;
    [$resolution->relations[0] === $query->inputRelation(), $resolution->missing[0]->describe()] // => [true, 'the declaration of relation t']

Properties§

public list<ResolvedColumn> $candidates
public list<Relation> $relations
public non-empty-list<MissingInput> $missing
public Name $name

Methods§

public function __construct(
    public Name $name,
    list<ResolvedColumn> $candidates,
    list<Relation> $relations,
    list<MissingInput> $missing,
)

Parameters

$nameNameThe column name
$candidateslist<ResolvedColumn>The known slots the name can resolve to
$relationslist<Relation>The incompletely known occurrences that can own the name
$missinglist<MissingInput>The inputs needed to decide the resolution; at least one
Calls 4

Test cases 15§

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

Dedicated tests 3
Other tests reaching this symbol 12

Relations§

Instantiated in 3
Type checks 3
Type declarations 1