 Documentation
      ¶
      Documentation
      ¶
    
    
  
    
  
    Index ¶
- func GenModulesCmd(name, version string, modulesFactory modulesManagerFactory) *cobra.Command
- type BeatsRootCmd
- func GenRootCmd(name, version string, beatCreator beat.Creator) *BeatsRootCmd
- func GenRootCmdWithIndexPrefixWithRunFlags(name, indexPrefix, version string, beatCreator beat.Creator, ...) *BeatsRootCmd
- func GenRootCmdWithRunFlags(name, version string, beatCreator beat.Creator, runFlags *pflag.FlagSet) *BeatsRootCmd
 
- type ModulesManager
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type BeatsRootCmd ¶
type BeatsRootCmd struct {
	cobra.Command
	RunCmd        *cobra.Command
	SetupCmd      *cobra.Command
	VersionCmd    *cobra.Command
	CompletionCmd *cobra.Command
	ExportCmd     *cobra.Command
	TestCmd       *cobra.Command
}
    BeatsRootCmd handles all application command line interface, parses user flags and runs subcommands
func GenRootCmd ¶
func GenRootCmd(name, version string, beatCreator beat.Creator) *BeatsRootCmd
GenRootCmd returns the root command to use for your beat. It takes beat name as parameter, and also run command, which will be called if no args are given (for backwards compatibility)
func GenRootCmdWithIndexPrefixWithRunFlags ¶
func GenRootCmdWithRunFlags ¶
func GenRootCmdWithRunFlags(name, version string, beatCreator beat.Creator, runFlags *pflag.FlagSet) *BeatsRootCmd
GenRootCmdWithRunFlags returns the root command to use for your beat. It takes beat name as parameter, and also run command, which will be called if no args are given (for backwards compatibility). runFlags parameter must the flagset used by run command
type ModulesManager ¶
type ModulesManager interface {
	ListEnabled() []*cfgfile.CfgFile
	ListDisabled() []*cfgfile.CfgFile
	Exists(name string) bool
	Enabled(name string) bool
	Enable(name string) error
	Disable(name string) error
}
    ModulesManager interface provides all actions needed to implement modules command (to list, enable & disable modules)
       Source Files
      ¶
      Source Files
      ¶
    
- completion.go
- export.go
- modules.go
- root.go
- run.go
- setup.go
- test.go
- version.go