Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ReplacerToUpper is a replacer which replaces lower cases by upper cases ReplacerToUpper = ReplacerFunc(func(s string) string { return strings.ToUpper(s) }) // ReplacerToLower is a replacer which replaces upper cases to lower cases ReplacerToLower = ReplacerFunc(func(s string) string { return strings.ToLower(s) }) // ReplacerTrimSpace is a replacer which removes spaces ReplacerTrimSpace = ReplacerFunc(func(s string) string { return strings.Trim(s, " ") }) )
Functions ¶
This section is empty.
Types ¶
type Replacer ¶
type Replacer interface { Replace(s string) string WriteString(w io.Writer, s string) (n int, err error) }
Replacer is an interface to characters of a string
type ReplacerFunc ¶
ReplacerFunc is a function which implements the Replacer interface
func (ReplacerFunc) WriteString ¶
WriteString writes to w the string s with replacement applied by f
Click to show internal directories.
Click to hide internal directories.