transformers

package
Version: v0.0.0-...-efb5a3d Latest Latest
Warning

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

Go to latest
Published: May 27, 2020 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ParameterizedTransformFunc

type ParameterizedTransformFunc func(params map[string]string) TransformFunc

func Lookup

func Lookup(name string) (ParameterizedTransformFunc, error)

Lookup returns a transformation function by name, or an error.

type TransformFunc

type TransformFunc func(interface{}) string

func DurationToHumanDuration

func DurationToHumanDuration(params map[string]string) TransformFunc

DurationToHumanDuration attempts to parse the string as a timestamp.

func Identity

func Identity(params map[string]string) TransformFunc

Identity is the identity function that always returns its input.

func QuantityRatio

func QuantityRatio(params map[string]string) TransformFunc

func TimeToHumanDuration

func TimeToHumanDuration(params map[string]string) TransformFunc

TimeToHumanDuration attempts to parse the string as a timestamp.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
t or T : Toggle theme light dark auto
y or Y : Canonical URL