PathSegmentSelectorBuilder

object PathSegmentSelectorBuilder

A helper object for building instances of RouteSelector from path segments.

Functions

Link copied to clipboard
fun parseConstant(value: String): RouteSelector

Builds a RouteSelector to match a constant or wildcard segment parameter.

fun parseConstant(value: String, hasTrailingSlash: Boolean): RouteSelector

Builds a RouteSelector to match a constant or wildcard segment parameter and trailing slash, if any.

Link copied to clipboard
fun parseName(value: String): String

Parses a name out of segment specification.

Link copied to clipboard
fun parseParameter(value: String): RouteSelector

Builds a RouteSelector to match a path segment parameter with a prefix/suffix and name.

fun parseParameter(value: String, hasTrailingSlash: Boolean): RouteSelector

Builds a RouteSelector to match a path segment parameter with a prefix/suffix, name, and trailing slash, if any.