Documentation ¶
Index ¶
- Constants
- func Init(bp *coremain.BP, args interface{}) (coremain.Plugin, error)
- func MustRegQuickSetup(typ string, f QuickSetupFunc)
- func RegQuickSetup(typ string, f QuickSetupFunc) error
- type Args
- type BQ
- type ChainWalker
- type Executable
- type ExecutableFunc
- type MatchConfig
- type MatchFunc
- type Matcher
- type QuickConfigurable
- type QuickSetupFunc
- type RecursiveExecutable
- type RecursiveExecutableFunc
- type RuleArgs
- type RuleConfig
Constants ¶
View Source
const PluginType = "sequence"
Variables ¶
This section is empty.
Functions ¶
func MustRegQuickSetup ¶
func MustRegQuickSetup(typ string, f QuickSetupFunc)
func RegQuickSetup ¶
func RegQuickSetup(typ string, f QuickSetupFunc) error
Types ¶
type ChainWalker ¶
type ChainWalker struct {
// contains filtered or unexported fields
}
func NewTestChainWalker ¶
func NewTestChainWalker(nextExec RecursiveExecutable) ChainWalker
NewTestChainWalker returns a ChainWalker which ChainWalker.ExecNext will always call nextExec with a noop ChainWalker. Note: As the function name indicates, this is for tests only.
func (*ChainWalker) ExecNext ¶
func (w *ChainWalker) ExecNext(ctx context.Context, qCtx *query_context.Context) error
type Executable ¶
type Executable interface {
Exec(ctx context.Context, qCtx *query_context.Context) error
}
Executable represents something that is executable.
func ToExecutable ¶
func ToExecutable(v any) Executable
type ExecutableFunc ¶
type ExecutableFunc func(ctx context.Context, qCtx *query_context.Context) error
func (ExecutableFunc) Exec ¶
func (f ExecutableFunc) Exec(ctx context.Context, qCtx *query_context.Context) error
type MatchConfig ¶
type QuickConfigurable ¶
QuickConfigurable can configure an exiting plugin with additional args. Expecting return is an Executable or RecursiveExecutable or Matcher.
type QuickSetupFunc ¶
QuickSetupFunc configures an Executable or RecursiveExecutable or Matcher. with a simple string args.
func GetQuickSetup ¶
func GetQuickSetup(typ string) QuickSetupFunc
type RecursiveExecutable ¶
type RecursiveExecutable interface {
Exec(ctx context.Context, qCtx *query_context.Context, next ChainWalker) error
}
RecursiveExecutable represents something that is executable and requires stack.
type RecursiveExecutableFunc ¶
type RecursiveExecutableFunc func(ctx context.Context, qCtx *query_context.Context, next ChainWalker) error
func (RecursiveExecutableFunc) Exec ¶
func (f RecursiveExecutableFunc) Exec(ctx context.Context, qCtx *query_context.Context, next ChainWalker) error
type RuleConfig ¶
type RuleConfig struct { Matches []MatchConfig `yaml:"matches"` Tag string `yaml:"tag"` Type string `yaml:"type"` Args string `yaml:"args"` }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.