Skip to content

You're viewing documentation for a pre-release version. View the latest stable version

Structure

TrieRouterBuilder

TrieRouterBuilder provides an efficient way to build routing tables by accumulating route registrations and then constructing an immutable, thread-safe TrieRouter for fast lookups.
struct TrieRouterBuilder<Output> where Output : Sendable

Configuration Options

  • .caseInsensitive: Enables case-insensitive route matching

Note: Route registration is cumulative - each call to register(_:at:) adds to the existing routes. Registering the same path twice will override the previous output.

Important: The builder uses immutable data structures internally, so route registration requires mutating access but the final router is completely immutable.

See Trie on Wikipedia for more information about the underlying data structure.

Topics

Initializers

Instance Properties

Instance Methods

Relationships

Conforms To