Uint16 defines a uint flag with specified name, default value, and usage string. The return value is the address of a uint variable that stores the value of the flag.
(name string, value uint16, usage string)
| 64 | // Uint16 defines a uint flag with specified name, default value, and usage string. |
| 65 | // The return value is the address of a uint variable that stores the value of the flag. |
| 66 | func (f *FlagSet) Uint16(name string, value uint16, usage string) *uint16 { |
| 67 | p := new(uint16) |
| 68 | f.Uint16VarP(p, name, "", value, usage) |
| 69 | return p |
| 70 | } |
| 71 | |
| 72 | // Uint16P is like Uint16, but accepts a shorthand letter that can be used after a single dash. |
| 73 | func (f *FlagSet) Uint16P(name, shorthand string, value uint16, usage string) *uint16 { |