utils

package
v0.7.3 Latest Latest
Warning

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

Go to latest
Published: Oct 2, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DestringifyValue

func DestringifyValue(Data string) (interface{}, error)

func FilterDuplicatesInStringArray added in v0.6.26

func FilterDuplicatesInStringArray(items []string) []string

func IsPrimitiveType added in v0.6.24

func IsPrimitiveType(value interface{}) bool

func IsStringType added in v0.6.24

func IsStringType(val interface{}) bool

func IsValidJSON

func IsValidJSON(input string) bool

func IsValidYAML

func IsValidYAML(input string) bool

func ManifestToPayload

func ManifestToPayload(manifest models.ScopedVariableManifest, userId int32) models.Payload

func PartitionSlice added in v0.7.0

func PartitionSlice[T any](array []T, chunkSize int) [][]T

func PayloadToManifest

func PayloadToManifest(payload models.Payload) models.ScopedVariableManifest

func StringifyValue

func StringifyValue(data interface{}) (string, error)

func ToIntArray added in v0.6.28

func ToIntArray(interfaceArr []interface{}) []int

ToIntArray converts an array of interface{} back to an array of int

func ToInterfaceArray

func ToInterfaceArray(arr []string) []interface{}

ToInterfaceArray converts an array of string to an array of interface{}

func ToStringArray

func ToStringArray(interfaceArr []interface{}) []string

ToStringArray converts an array of interface{} back to an array of string

Types

This section is empty.

Jump to

Keyboard shortcuts

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