Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ErrNoDestination = errors.New("encountered prefix without a destination")
Functions ¶
This section is empty.
Types ¶
type InOrder ¶
InOrder implements wdresolve.Resolver and queries several child resolvers in order
type Prefix ¶
Prefix implements wdresolve.Resolver on the basis of a longest prefix match
func ReadPrefixes ¶
ReadPrefixes reads a set of prefixes from the provided reader
The reader should return data that contains one prefix per line. Leading and trailing spaces are ignored. A destination is indicated by a line ending in ":". Blank lines and those starting with "#" are ignored. For example:
# I am ignored https://wisski.example.com: http://wisski.example.com/ https://wisski.example.com/ https://wisski.other.com: http://wisski.other.com/ https://wisski.other.com/
type Regexp ¶
Regexp implements [wdresolver.Resolver] on the basis of a regexp mapping.
It should contain a map from regular expressions for URIs to target WissKI deployments. Keys are encoded as regular expressions, Values may contain the $n$ syntax to replace matched groups.
The behaviour when multiple keys match is non-deterministic, as any value might be used as a response.