Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ApplyAll ¶
func ApplyAll(filter ast.FilterNode, passes []CompilerPass) (ast.FilterNode, error)
ApplyAll applies all the compiler passes serially and returns the resulting tree. This method copies the passes AST before executing the compiler passes.
Types ¶
type CompilerPass ¶
type CompilerPass interface { // Exec executes the pass on the provided AST. This method may either return // a new AST or the existing modified AST. Note that the parameter to this // method may be changed directly. Exec(filter ast.FilterNode) (ast.FilterNode, error) }
CompilerPass is an interface which defines an implementation capable of accepting an input AST and making optimizations or changes, and returning a new (or the existing) AST.
func PrometheusKeySanitizePass ¶
func PrometheusKeySanitizePass() CompilerPass
PrometheusKeySanitizePass returns a
func UnallocatedReplacementPass ¶
func UnallocatedReplacementPass() CompilerPass
UnallocatedReplacementPass returns a CompilerPass implementation which replaces all __unallocated__ with empty string
Click to show internal directories.
Click to hide internal directories.