Documentation ¶ Index ¶ func Tokenize(corpus string, tokens Tokens) string type Tokens Constants ¶ This section is empty. Variables ¶ This section is empty. Functions ¶ func Tokenize ¶ func Tokenize(corpus string, tokens Tokens) string Tokenize replaces a given set of tokens in a corpus. Tokens should appear in the corpus in the form ${[KEY]} where [KEY] is the key in the map. Examples: corpus: "foo/${bar}/baz", { "bar": "bailey" } => "foo/bailey/baz" UTF-8 is handled via. runes. Types ¶ type Tokens ¶ type Tokens = map[string]string Tokens is a soft alias to map[string]string Source Files ¶ View all Source files tokenize.go Click to show internal directories. Click to hide internal directories.