util

package
v0.5.3-beta.6 Latest Latest
Warning

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

Go to latest
Published: Jun 25, 2023 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComputeHash

func ComputeHash(object interface{}) (string, error)

func Difference

func Difference(left, right *set.LinkedHashSetString) *set.LinkedHashSetString

func EqSet

func EqSet(left, right *set.LinkedHashSetString) bool

func FromConfigFiles

func FromConfigFiles(files []string) (map[string]string, error)

func JSONPatch

func JSONPatch(originalJSON, modifiedJSON interface{}) ([]byte, error)

func MapKeyDifference

func MapKeyDifference[T interface{}](left, right map[string]T) *set.LinkedHashSetString

func Max

func Max[T constraints.Ordered](l, r T) T

func Min

func Min[T constraints.Ordered](l, r T) T

func RetrievalWithJSONPath

func RetrievalWithJSONPath(jsonObj interface{}, jsonpath string) ([]byte, error)

func ToSet

func ToSet[T interface{}](v map[string]T) *set.LinkedHashSetString

func Union

func Union(left, right *set.LinkedHashSetString) *set.LinkedHashSetString

func UnstructuredObjectWalk

func UnstructuredObjectWalk(data interface{}, fn NodeProcessFn, onlyAccessNode bool) error

Types

type NodeProcessFn

type NodeProcessFn func(parent, cur string, v reflect.Value, fn UpdateFn) error

type UpdateFn

type UpdateFn func(v interface{})

Jump to

Keyboard shortcuts

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