bech32m

package
v1.0.16 Latest Latest
Warning

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

Go to latest
Published: May 23, 2022 License: GPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Bech32  = 1
	Bech32m = 2
	Failed  = -1

	VersionPrefix = 1
	VersionSuffix = 2
)

Enumeration type to list the various supported encodings.

Variables

This section is empty.

Functions

func Bech32mDecode

func Bech32mDecode(address, prefix string, charset string) ([]byte, error)

func Bech32mEncode

func Bech32mEncode(prefix string, data []byte, charset string) (string, error)

func Convertbits

func Convertbits(data []byte, frombits, tobits uint, pad bool) ([]byte, error)

func Decode

func Decode(bechString string, charset string) (string, []byte, int, error)

Decode validate a Bech32/Bech32m string, and determine HRP and data.

func Encode

func Encode(hrp string, data []byte, spec int, charset string) string

Encode compute a Bech32 string given HRP and data values.

Types

This section is empty.

Jump to

Keyboard shortcuts

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