PathSegment

sealed interface PathSegment

A named step in a KeyPath or CaseKeyPath structural identity.

Inheritors

Types

Link copied to clipboard
data class Case(val name: String) : PathSegment

A sealed or enum CaseKeyPath segment.

Link copied to clipboard
data class Custom(val name: String) : PathSegment

A caller-defined KeyPath segment intentionally distinct from a declared property.

Link copied to clipboard
data object ForceUnwrap : PathSegment

A force-unwrapping step that fails when its intermediate value is null.

Link copied to clipboard
data class Index(val value: Int) : PathSegment

An indexed collection KeyPath segment.

Link copied to clipboard
data class Key(val value: Any?) : PathSegment

A keyed map KeyPath segment.

Link copied to clipboard

A conditional optional-chaining step.

Link copied to clipboard
data class Property(val name: String) : PathSegment

A declared property KeyPath segment.