Skip to content

ApiIndex

Every documented class, plus the lookups the emitters need across them.

Cross-linking and the “implemented by” back-index both need to see the whole corpus, so they are resolved once here rather than rediscovered per page.

final class ApiIndex

SourceIr/ApiIndex.php

public function __construct(list<ClassDoc> $classes, Slugger $slugger = new Slugger(…)): mixed

ParameterTypeDescription
$classeslist``<ClassDoc>
$sluggerSlugger

Returns mixed

MethodDescription
classes(): list<ClassDoc>
get(string $fqcn): ?ClassDoc
has(string $fqcn): bool
inNamespace(string $namespace): list<ClassDoc>
namespaces(): list<string>
navigableNamespaces(): list<string>Every namespace that needs a page, including the ones holding nothing but other namespaces.
slugFor(string $fqcn): ?stringThe page path for a documented class, or null when it is not part of the reference.
slugger(): Slugger
topLevelNamespaces(): list<string>The namespaces the reference lists in its navigation: one level below the framework root, which is the granularity a sidebar can carry without putting every class on every page.
under(string $namespace): list<ClassDoc>

public function classes(): list<ClassDoc>

Returns list``<ClassDoc> — Ordered by fully-qualified name.

public function get(string $fqcn): ?ClassDoc

ParameterTypeDescription
$fqcnstring

Returns ?ClassDoc

public function has(string $fqcn): bool

ParameterTypeDescription
$fqcnstring

Returns bool

public function inNamespace(string $namespace): list<ClassDoc>

ParameterTypeDescription
$namespacestring

Returns list``<ClassDoc>

public function namespaces(): list<string>

Returns list``<``string``> — Namespaces that hold at least one class, ordered by name.

public function navigableNamespaces(): list<string>

Every namespace that needs a page, including the ones holding nothing but other namespaces.

Quiote\Config\Util declares no types of its own, only Quiote\Config\Util\DOM below it. It still has to exist as a page, because the level above links to it on the way down.

Returns list``<``string``>

public function slugFor(string $fqcn): ?string

The page path for a documented class, or null when it is not part of the reference.

ParameterTypeDescription
$fqcnstring

Returns ?``string

public function slugger(): Slugger

Returns Slugger

public function topLevelNamespaces(): list<string>

The namespaces the reference lists in its navigation: one level below the framework root, which is the granularity a sidebar can carry without putting every class on every page.

Returns list``<``string``>

public function under(string $namespace): list<ClassDoc>

ParameterTypeDescription
$namespacestring

Returns list``<ClassDoc> — Every class at or below $namespace.