MCPcopy
hub / github.com/spf13/cobra / HasAvailableFlags

Method HasAvailableFlags

command.go:1822–1824  ·  view source on GitHub ↗

HasAvailableFlags checks if the command contains any flags (local plus persistent from the entire structure) which are not hidden or deprecated.

()

Source from the content-addressed store, hash-verified

1820// HasAvailableFlags checks if the command contains any flags (local plus persistent from the entire
1821// structure) which are not hidden or deprecated.
1822func (c *Command) HasAvailableFlags() bool {
1823 return c.Flags().HasAvailableFlags()
1824}
1825
1826// HasAvailablePersistentFlags checks if the command contains persistent flags which are not hidden or deprecated.
1827func (c *Command) HasAvailablePersistentFlags() bool {

Callers 7

UseLineMethod · 0.95
manPrintOptionsFunction · 0.80
printOptionsReSTFunction · 0.80
printOptionsFunction · 0.80

Calls 1

FlagsMethod · 0.95

Tested by

no test coverage detected