utils

package
v1.6.7 Latest Latest
Warning

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

Go to latest
Published: May 31, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CompareHashAndString

func CompareHashAndString(hash string, secret string) bool

CompareHashAndString is used to verify that a string matches a provided hash

func ExtractCoinPointerFromString

func ExtractCoinPointerFromString(amount string) (*sdk.Coin, error)

ExtractCoinPointerFromString Return a coin instance pointer from a string

func GenerateHashFromString

func GenerateHashFromString(secret string) []byte

GenerateHashFromString is used to generate a hashed version of the argument passed string

func GenerateSecureToken

func GenerateSecureToken(length int) string

GenerateSecureToken Generate a secure random token of the given length and return string

func RemoveFromArray

func RemoveFromArray[T comparable](l []T, item T) []T

Types

This section is empty.

Jump to

Keyboard shortcuts

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