guid

package
v0.62.6 Latest Latest
Warning

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

Go to latest
Published: Dec 24, 2023 License: MIT Imports: 4 Imported by: 1

Documentation

Overview

encoding/guid supports encoding and decoding Guid values.

Index

Constants

View Source
const (
	// GuidPattern is a regexp pattern for GUIDs.
	GUIDPattern = `^([0-9a-fA-F]{8})-?([0-9a-fA-F]{4})-?([0-9a-fA-F]{4})-?([0-9a-fA-F]{4})-?([0-9a-fA-F]{12})$`
)

Variables

This section is empty.

Functions

func Base58ToGUID added in v0.37.0

func Base58ToGUID(b58str string, inclHyphen bool) (string, error)

Base58ToGUID converts a Base58 string to a GUID string, with or without hyphens, using the Bitcoin alphabet.

func GUIDToBase58 added in v0.37.0

func GUIDToBase58(guid string) (string, error)

GUIDToBase58 converts a GUID string to a Base58 string using the Bitcoin alphabet.

func GUIDToBigInt added in v0.37.0

func GUIDToBigInt(guid string) (*big.Int, error)

GUIDToBigInt converts a GUID string, with or with out hypens, to a *big.Int.

func ValidGUIDHex added in v0.37.0

func ValidGUIDHex(guid string) bool

ValidGUIDHex checks to see if a string is a valid GUID.

Types

This section is empty.

Jump to

Keyboard shortcuts

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