Skip to content

Multiplatform Ktor schema declarationopensavvy.spine.apiPath

Path

class Path(val segments: List<Path.Segment>) : Iterable<Path.Segment> , Addressed

The path section in a URL.

Constructors

Path

constructor(segments: List<Path.Segment>)

constructor(vararg segments: String)

Convenience constructor that builds a Path from a list of string segments.

Types

Segment

@JvmInline
value class Segment(val text: String)

A single segment of a URL Path.

Properties

path

open override val path: Path

segments

Functions

equals

open operator override fun equals(other: Any?): Boolean

hashCode

open override fun hashCode(): Int

iterator

open operator override fun iterator(): Iterator<Path.Segment>

plus

operator fun plus(other: String): Path

Returns a new Path with other appended as the last segment.

operator fun plus(other: Path.Segment): Path

Returns a new Path with other appended as the last segment.

toString

open override fun toString(): String