address

package
v1.8.6 Latest Latest
Warning

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

Go to latest
Published: Dec 6, 2022 License: BSD-3-Clause Imports: 5 Imported by: 5 modules, 15 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Format

func Format(chainIDAlias string, hrp string, addr []byte) (string, error)

Format takes in a chain prefix, HRP, and byte slice to produce a string for an address.

func FormatBech32

func FormatBech32(hrp string, payload []byte) (string, error)

FormatBech32 takes an address's bytes as input and returns a bech32 address

func Parse

func Parse(addrStr string) (string, string, []byte, error)

Parse takes in an address string and splits returns the corresponding parts. This returns the chain ID alias, bech32 HRP, address bytes, and an error if it occurs.

func ParseBech32

func ParseBech32(addrStr string) (string, []byte, error)

ParseBech32 takes a bech32 address as input and returns the HRP and data section of a bech32 address

func ParseToID

func ParseToID(addrStr string) (ids.ShortID, error)

func ParseToIDs

func ParseToIDs(addrStrs []string) ([]ids.ShortID, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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