utils

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Dec 7, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddHeaders added in v0.1.3

func AddHeaders(request *http.Request, headers map[string]string)

func AddJsonHeader added in v0.1.3

func AddJsonHeader(request *http.Request)

func GetPointer added in v0.1.2

func GetPointer[T PointerAble](value T) *T

func SliceToString

func SliceToString[T any](slice []T) string

SliceToString converts a slice of anonymous type T to a string

Types

type PointerAble added in v0.1.2

type PointerAble interface {
	constraints.Integer | constraints.Unsigned | string
}

PointerAble define an interface that can change to pointer, include string, int, int64, unit

Jump to

Keyboard shortcuts

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