@@ -20,11 +20,11 @@ Out of the box, the following case conversion are supported:
2020- Title Case (e.g. Title Case)
2121- Other deliminations
2222
23- Word boundaries are determined by the ` caps.Formatter ` . The provided implementation, ` caps.FormatterImpl ` ,
23+ Word boundaries are determined by the ` caps.Converter ` . The provided implementation, ` caps.ConverterImpl ` ,
2424delegates the boundary detection to ` caps.Tokenizer ` . The provided implementation, ` caps.TokenizerImpl ` ,
2525uses the following runes as delimiters: ` " _.!?:;$-(){}[]#@&+~" ` .
2626
27- ` caps.StdFormatter ` also allows users to register ` caps.Replacement ` s for acronym replacement. The default list is:
27+ ` caps.StdConverter ` also allows users to register ` caps.Replacement ` s for acronym replacement. The default list is:
2828
2929``` go
3030{" Http" , " HTTP" }
@@ -43,14 +43,14 @@ uses the following runes as delimiters: `" _.!?:;$-(){}[]#@&+~"`.
4343If you would like to add or remove entries from that list, you have a few
4444options.
4545
46- You can pass a new instance of ` caps.StdFormatter ` with a new set of
46+ You can pass a new instance of ` caps.StdConverter ` with a new set of
4747` caps.Replacement ` (likely preferred).
4848
49- You can create your own ` caps.Formatter ` . This could be as simple as
50- implementing the single ` Format ` method, calling ` caps.DefaultFormatter.Format ` ,
49+ You can create your own ` caps.Converter ` . This could be as simple as
50+ implementing the single ` Convert ` method, calling ` caps.DefaultConverter.Convert ` ,
5151and then modifying the result.
5252
53- Finally, if you are so inclined, you can update ` caps.DefaultFormatter ` . Just be aware that the
53+ Finally, if you are so inclined, you can update ` caps.DefaultConverter ` . Just be aware that the
5454module was not built with thread-safety in mind so you should set it once.
5555Otherwise, you'll need guard your usage of the library accordingly.
5656
0 commit comments