Path

class Path

Represents a hierarchical path to a nested scope within the DI container. A path is essentially a sequence of Qualifiers that defines the route from a starting scope to a target descendant scope. The path is resolved in reverse order of appendage, moving from the target scope up to the root.

Constructors

Link copied to clipboard
constructor()

Creates an empty path.

constructor(initialValue: Qualifier)

Creates a path with an initial qualifier.

Properties

Link copied to clipboard

A read-only list of the qualifiers that make up the path, in the order they should be resolved.

Functions

Link copied to clipboard
fun append(qualifier: Qualifier)

Prepends a Qualifier to the path. Since the path is built from the target scope upwards, append actually adds the qualifier to the front of the resolution order.