helper

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 11, 2021 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Overview

Package helper provide some basic utility functions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BoolPointer

func BoolPointer(b bool) *bool

BoolPointer returns a pointer on given bool

func ContainsElements

func ContainsElements(ref, elems map[string]string) bool

ContainsElements returns if a given map[string]string contains all elements given in parameter.

func ContainsString

func ContainsString(slice []string, s string) bool

ContainsString returns if given slice contains string.

func Int32Pointer

func Int32Pointer(i int32) *int32

Int32Pointer returns a pointer on given int32

func Int64Pointer

func Int64Pointer(i int64) *int64

Int64Pointer returns a pointer on given int64

func Int64PointerOrNil

func Int64PointerOrNil(i int64) *int64

Int64PointerOrNil returns a pointer on given int or nil if zero

func RemoveString

func RemoveString(slice []string, s string) (result []string)

RemoveString remove given string from given slice and returns it.

func StringPointer

func StringPointer(s string) *string

StringPointer converts a string value to a string pointer.

func StringPointerOrNil

func StringPointerOrNil(s string) *string

StringPointerOrNil converts a string value to a string pointer or nil if empty string.

func StringValue

func StringValue(s *string) string

StringValue converts a string pointer to a string value.

Types

This section is empty.

Jump to

Keyboard shortcuts

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