helper

package
v1.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 18, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func IsNil

func IsNil(actual interface{}) bool

func IsSlice

func IsSlice(actual interface{}) bool

func IterateOverSlice

func IterateOverSlice(actual interface{}, visitor func(value interface{}) bool)

IterateOverSlice iterates over the provides interface{} until all elements were visited or until the visior returns false

func MatchElementsInSlice

func MatchElementsInSlice(actual interface{}, matcher func(actual interface{}) (success bool, err error)) (bool, error)

MatchElementsInSlice applies a matcher individually to each element in the slice and returns as soon as the matcher fails on an element.

func ToPointer

func ToPointer(actual interface{}) interface{}

ToPointer returns a new pointer to the provided interface{}, if the provided value is not already a pointer. if the original value is already a pointer it gets returned directly.

func ToUnstructured

func ToUnstructured(actual interface{}) (*unstructured.Unstructured, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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