texpr

package
v0.4.3 Latest Latest
Warning

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

Go to latest
Published: Feb 2, 2021 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Expr

type Expr struct {
	// contains filtered or unexported fields
}

Expr can be evaluated.

func Parse

func Parse(expr, def string) (*Expr, error)

Parse returns a parsed expr. An empty expr evaluates to def. Expressions use https://golang.org/pkg/text/template/ syntax without the curlies.

func (Expr) Evaluate

func (ex Expr) Evaluate(data interface{}) (string, error)

Evaluate the receiver with data.

Jump to

Keyboard shortcuts

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