Skip to main content

Module path

Module path 

Source
Expand description

Broadcast paths and the patterns that match them.

Path is a literal coordinate: /-separated segments, normalized, with segment-aware prefix operations. Pattern describes a set of paths with wildcards, and Patterns is a union of them reduced by containment. The grammar and algebra live in moq-pattern; this module re-exports them beside Path so grants, origin scopes, announce interests, and wildcard advertisements can share one dialect. Literal path construction and wire decoding retain their existing behavior.

Structs§

Path
A broadcast path that provides safe prefix matching operations.
Pattern
A pattern over broadcast paths: literal segments, * for one segment, prefix*suffix for one segment with a known start and end, and at most one ** for any run of segments. Every segment kind matches whole segments, and a pattern is exact: foo matches only foo, and a subtree is foo/**.
Patterns
A union of patterns, reduced so no member is contained by another.
Relative
A relative broadcast path, used to reference one broadcast from another broadcast’s content.
Specificity
How much of a path a pattern pins down, for ranking the patterns that match one path.

Enums§

InvalidPattern
Why a string or a segment list is not a valid Pattern.
Segment
One segment of a Pattern.

Traits§

AsPath
A trait for types that can be converted to a Path.

Type Aliases§

PathOwned
An owned version of Path with a 'static lifetime.
RelativeOwned
An owned version of Relative with a 'static lifetime.