tools

package
v0.179.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 18, 2023 License: AGPL-3.0, AGPL-3.0-or-later Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ContextWalk added in v0.64.6

func ContextWalk(context *types.XObject, callback func(types.XValue))

ContextWalk traverses the given context invoking the callback for each non-nil value

func ContextWalkObjects added in v0.64.6

func ContextWalkObjects(context *types.XObject, callback func(*types.XObject))

ContextWalkObjects traverses the given context invoking the callback for each object found

func FindContextRefsInTemplate

func FindContextRefsInTemplate(template string, allowedTopLevels []string, callback func([]string)) error

FindContextRefsInTemplate audits context references in the given template. Note that the case of the found references is preserved as these may be significant, e.g. ["X"] vs ["x"] in JSON

func RefactorTemplate

func RefactorTemplate(template string, allowedTopLevels []string) (string, error)

RefactorTemplate refactors the passed in template

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL