WithHandles allows you to customize the short handles for the answers.
(handles []string)
| 79 | |
| 80 | // WithHandles allows you to customize the short handles for the answers. |
| 81 | func (p InteractiveContinuePrinter) WithHandles(handles []string) *InteractiveContinuePrinter { |
| 82 | if len(handles) != len(p.Options) { |
| 83 | Warning.Printf("%v is not a valid set of handles", handles) |
| 84 | p.setDefaultHandles() |
| 85 | return &p |
| 86 | } |
| 87 | p.Handles = handles |
| 88 | return &p |
| 89 | } |
| 90 | |
| 91 | // WithShowShortHandles will set ShowShortHandles to true |
| 92 | // this makes the printer display the shorthand options instead their shorthand version. |